Skip to content

Commit

Permalink
add utils::unzip() to importFrom list
Browse files Browse the repository at this point in the history
  • Loading branch information
fsolt committed May 23, 2019
1 parent 08b66ca commit c02a84a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ export(icpsr_download)
import(RSelenium)
importFrom(purrr,walk)
importFrom(stringr,str_detect)
importFrom(utils,unzip)
3 changes: 2 additions & 1 deletion R/icpsrdownload.R
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
#' @import RSelenium
#' @importFrom purrr walk
#' @importFrom stringr str_detect
#' @importFrom utils unzip
#'
#' @export
icpsr_download <- function(file_id,
Expand Down Expand Up @@ -117,7 +118,7 @@ icpsr_download <- function(file_id,
}

# unzip into specified directory
unzip(file.path(default_dir, dd_new), exdir = file.path(download_dir))
utils::unzip(file.path(default_dir, dd_new), exdir = file.path(download_dir))
unlink(file.path(default_dir, dd_new))
})

Expand Down

0 comments on commit c02a84a

Please sign in to comment.