Skip to content

Commit a3a1655

Browse files
authored
Merge pull request #184 from rolfsimoes/dev
Fix simplify_vector parameter
2 parents 620398b + d858eb5 commit a3a1655

7 files changed

Lines changed: 10 additions & 9 deletions

File tree

R/ext_filter.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -265,8 +265,8 @@ before_request.ext_filter <- function(q) {
265265
}
266266

267267
#' @export
268-
after_response.ext_filter <- function(q, res) {
269-
after_response.items(q, res)
268+
after_response.ext_filter <- function(q, res, simplify_vector = TRUE) {
269+
after_response.items(q, res, simplify_vector)
270270
}
271271

272272
#' @export

R/ext_query.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,8 @@ before_request.ext_query <- function(q) {
118118
}
119119

120120
#' @export
121-
after_response.ext_query <- function(q, res) {
122-
after_response.items(q, res)
121+
after_response.ext_query <- function(q, res, simplify_vector = TRUE) {
122+
after_response.items(q, res, simplify_vector)
123123
}
124124

125125
#' @export

R/extensions.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ content_response <- function(res, status_codes, content_types, key_message,
165165
res,
166166
type = "application/json",
167167
encoding = "UTF-8",
168-
simplifyVector = TRUE,
168+
simplifyVector = simplify_vector,
169169
simplifyDataFrame = FALSE,
170170
simplifyMatrix = FALSE
171171
)

R/search-query.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,6 @@ before_request.search <- function(q) {
148148
}
149149

150150
#' @export
151-
after_response.search <- function(q, res) {
152-
after_response.items(q, res)
151+
after_response.search <- function(q, res, simplify_vector = TRUE) {
152+
after_response.items(q, res, simplify_vector)
153153
}

man/preview_plot.Rd

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/testthat/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Rplots.pdf

tests/testthat/test-items_functions.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@ testthat::test_that("items functions", {
320320
item <- stac("https://stac.core.eopf.eodc.eu/") %>%
321321
collections(collection_id = "sentinel-2-l2a") %>%
322322
items(limit = 1) %>%
323-
get_request(FALSE)
323+
get_request(simplify_vector = FALSE)
324324

325325
item$features[[1]]$properties$instrument
326326
},

0 commit comments

Comments
 (0)