Skip to content

Commit

Permalink
cleaning up dev to enable merge with main
Browse files Browse the repository at this point in the history
  • Loading branch information
yannikbuhl committed Dec 5, 2024
1 parent d448815 commit e8d7a6c
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 7 deletions.
3 changes: 0 additions & 3 deletions R/gen_api.R
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
#' @description Low-level function to interact with the GENESIS API
#'
#' @param endpoint Character string. The endpoint of the API that is to be queried.
#' @param overwrite_url Character string. In certain cases it is required to set a custom URL for the respective API. By specifying the URL in this parameter, the API calls will be directed to this custom URL. But be aware, the URL has to lead to the same database (in this case: GENESIS), else there will be errors. Hence, use with caution.
#' @param ... Further parameters passed on to the final API call.
#'
#' @importFrom httr2 `%>%`
Expand Down Expand Up @@ -55,7 +54,6 @@ gen_genesis_api <- function(endpoint,
#' @description Low-level function to interact with the regionalstatistik.de API
#'
#' @param endpoint Character string. The endpoint of the API that is to be queried.
#' @param overwrite_url Character string. In certain cases it is required to set a custom URL for the respective API. By specifying the URL in this parameter, the API calls will be directed to this custom URL. But be aware, the URL has to lead to the same database (in this case: www.regionalstatistik.de), else there will be errors. Hence, use with caution.
#' @param ... Further parameters passed on to the final API call.
#'
#' @importFrom httr2 `%>%`
Expand Down Expand Up @@ -90,7 +88,6 @@ gen_regio_api <- function(endpoint,
#' @description Low-level function to interact with the Zensus 2022 database
#'
#' @param endpoint Character string. The endpoint of the API that is to be queried.
#' @param overwrite_url Character string. In certain cases it is required to set a custom URL for the respective API. By specifying the URL in this parameter, the API calls will be directed to this custom URL. But be aware, the URL has to lead to the same database (in this case: Zensus 2022), else there will be errors. Hence, use with caution.
#' @param ... Further parameters passed on to the final API call.
#'
#' @importFrom httr2 `%>%`
Expand Down
2 changes: 1 addition & 1 deletion R/gen_cube.R
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ gen_cube_ <- function(name,
classifyingvariable3 = NULL,
classifyingkey3 = NULL,
stand = NULL,
language = Sys.getenv("RESTATIS_LANG")) {
language = Sys.getenv("GENESIS_LANG")) {

area <- match.arg(area)
database <- match.arg(database)
Expand Down
2 changes: 1 addition & 1 deletion R/gen_jobs.R
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ gen_download_job <- function(name,
database = c("genesis", "regio"),
area = c("all", "public", "user"),
compress = FALSE,
language = Sys.getenv("RESTATIS_LANG"),
language = Sys.getenv("GENESIS_LANG"),
all_character = TRUE) {

#-----------------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion R/gen_table.R
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ gen_table_ <- function(name,
classifyingvariable3 = NULL,
classifyingkey3 = NULL,
stand = NULL,
language = Sys.getenv("RESTATIS_LANG"),
language = Sys.getenv("GENESIS_LANG"),
job = FALSE,
all_character = TRUE) {

Expand Down
2 changes: 1 addition & 1 deletion R/zzz.R
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
gen_regio_api <<- memoise::memoise(gen_regio_api)

# Set the default language of the package
if (!nzchar(Sys.getenv("RESTATIS_LANG"))) Sys.setenv(RESTATIS_LANG = "en")
if (!nzchar(Sys.getenv("GENESIS_LANG"))) Sys.setenv(RESTATIS_LANG = "en")

# Set the default URL for the GENESIS database
if (!nzchar(Sys.getenv("RESTATIS_GENESIS_URL"))) {
Expand Down

0 comments on commit e8d7a6c

Please sign in to comment.