Skip to content

Commit

Permalink
Update R/tar-terra-vect.R
Browse files Browse the repository at this point in the history
Co-authored-by: Nicholas Tierney <njtierney@users.noreply.github.com>
  • Loading branch information
Aariq and njtierney committed Mar 14, 2024
1 parent a056755 commit 52a5aef
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions R/tar-terra-vect.R
Original file line number Diff line number Diff line change
Expand Up @@ -114,12 +114,12 @@ tar_terra_vect <- function(name,
gdal <- "ENCODING=UTF-8"
}

if (filetype == "ESRI Shapefile") {
#special handling of ESRI shapefiles because the output is a dir of multiple files.
format <- create_format_terra_vect_shz(options = gdal, ...)
} else {
format <- create_format_terra_vect(filetype, options = gdal, ...)
}
format <- ifelse(
test = filetype == "ESRI Shapefile",
#special handling of ESRI shapefiles because the output is a dir of multiple files.
yes = create_format_terra_vect_shz(options = gdal, ...),
no = create_format_terra_vect(filetype, options = gdal, ...)
)

targets::tar_target_raw(
name = name,
Expand Down

0 comments on commit 52a5aef

Please sign in to comment.