R/etc.R

get_local_file_path <- function(group, local_path){
  if(missing(local_path)){
    local_path <- fetch_session("storage_method.local_path", internal = T)
  }
  if(is.null(local_path)){
    warning("Local path is not set. Using .store folder.")
    local_path <- ".store"
  }

  if(!missing(group)){
    local_path <- file.path(local_path,group)
  }

  file_path <- file.path(local_path,"cache")

  return(file_path)
}
MadeInR/store documentation built on May 12, 2019, 8:41 a.m.