Skip to content

Commit

Permalink
up
Browse files Browse the repository at this point in the history
  • Loading branch information
Natanaelsl committed May 15, 2024
1 parent d1079ba commit a5d0b0f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions R/RGFdata.R
Original file line number Diff line number Diff line change
Expand Up @@ -356,12 +356,12 @@ RGFdata <- function(cod.ibge = NULL, ano = NULL, poder = NULL, periodo = NULL, a
}

# DEFININDO ESTRUTURA PARA MUNICÍPIOS
if(all(nchar(cod.ibge) == 7) & {simplificado} == TRUE & {periodo} == 3) {
if(all(nchar(cod.ibge) == 7) & {simplificado} == TRUE & (3 %in% periodo)) {
cli::cli_alert_danger("Simplified RGF applies only to municipalities with less than 50 thousand inhabitants that have opted for biannual publication of reports. Set `periodo` to 1 or 2.")

}

if((all(nchar(cod.ibge) == 7) & {simplificado} == TRUE & {periodo} != 3) | (all(nchar(cod.ibge) == 7) & {simplificado} == FALSE) ) {
if((all(nchar(cod.ibge) == 7) & {simplificado} == TRUE & !(3 %in% periodo)) | (all(nchar(cod.ibge) == 7) & {simplificado} == FALSE) ) {

for(z in 1:length(ano)) {
cli::cli_progress_step("EXTRACTING {ano[[z]]}", spinner = TRUE)
Expand Down
6 changes: 3 additions & 3 deletions R/siconfi_list.R
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,11 @@ siconfi_list <- function(options = NULL){

if (file.exists(caminho_arquivo)) {
utils::download.file(url, destfile = caminho_arquivo, mode = "wb")
cli::cli_alert_info("PDF file successfully downloaded and saved to: \n")
cat(caminho_arquivo)
cli::cli_alert_info("PDF file successfully downloaded and saved to: \n {.path {caminho_arquivo}}")


} else {
cat("The path provided does not exist:\n", caminho_arquivo)
cli::cli_alert_danger("The path provided does not exist:\n {.path {caminho_arquivo}}")
}

}
Expand Down

0 comments on commit a5d0b0f

Please sign in to comment.