Skip to content

Commit 6159bd8

Browse files
committed
Process response after download failure
Relates to #399
1 parent 0bb0070 commit 6159bd8

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

R/drive_download.R

+5
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,11 @@ drive_download <- function(file,
114114
"*" = "{.path {path}}"
115115
))
116116
} else {
117+
# drop this in to allow a post mortem inspection of failure
118+
# not how this would be wired up "in production"
119+
# puts the response within reach of the unexported functions
120+
# gargle:::gargle_last_response()` and gargle:::gargle_last_content()
121+
gargle::response_process(response)
117122
drive_abort("Download failed.")
118123
}
119124
invisible(put_column(file, nm = "local_path", val = path, .after = "name"))

0 commit comments

Comments
 (0)