Skip to content

Commit

Permalink
Fixed another bug in try_query
Browse files Browse the repository at this point in the history
  • Loading branch information
jpquast authored and elena-krismer committed Oct 17, 2024
1 parent badce14 commit d4674f0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/try_query.R
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ try_query <-
options(readr.show_progress = FALSE)

# Check if the content is gzip compressed
if (query_result$headers[["content-encoding"]] == "gzip") {
if (!is.null(query_result$headers[["content-encoding"]]) && query_result$headers[["content-encoding"]] == "gzip") {
# Retrieve the content as raw bytes using httr::content
raw_content <- httr::content(query_result, type = "raw")

Expand Down

0 comments on commit d4674f0

Please sign in to comment.