Skip to content

Commit

Permalink
minor cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
achubaty committed Aug 2, 2020
1 parent 54f0d38 commit 1e86c3b
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions R/postProcess.R
Expand Up @@ -1579,11 +1579,9 @@ postProcessAllSpatial <- function(x, studyArea, rasterToMatch, useCache, filenam
if (!is.null(studyArea) || !is.null(rasterToMatch) || !is.null(targetCRS)) {
attemptGDALAllAtOnce <- if (is(x, "RasterLayer")) attemptGDAL(x, useGDAL = useGDAL) else FALSE
if (isTRUE(attemptGDALAllAtOnce) ) {
x <- cropReprojMaskWGDAL(x, studyArea, rasterToMatch, targetCRS, cores, dots, filename2, useSAcrs,
...)
x <- cropReprojMaskWGDAL(x, studyArea, rasterToMatch, targetCRS, cores, dots, filename2,
useSAcrs, ...)
} else {


# fix errors if methods available
skipCacheMess <- "useCache is FALSE, skipping Cache"
skipCacheMess2 <- "No cacheRepo supplied"
Expand Down Expand Up @@ -1629,8 +1627,7 @@ postProcessAllSpatial <- function(x, studyArea, rasterToMatch, useCache, filenam
#buffer the new polygon by 1.5 the resolution of X so edges aren't cropped out
tempPoly <- raster::buffer(tempPoly, width = max(res(x))*1.5)
extRTM <- tempPoly
crsRTM <- suppressWarningsSpecific(falseWarnings = "CRS object has comment",
.crs(tempPoly))
crsRTM <- suppressWarningsSpecific(falseWarnings = "CRS object has comment", .crs(tempPoly))
} else {
bufferSA <- TRUE
origStudyArea <- studyArea
Expand Down

0 comments on commit 1e86c3b

Please sign in to comment.