diff options
Diffstat (limited to 'app/uploaders')
-rw-r--r-- | app/uploaders/object_storage.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/app/uploaders/object_storage.rb b/app/uploaders/object_storage.rb index be5839b7ec5..1d56cddca63 100644 --- a/app/uploaders/object_storage.rb +++ b/app/uploaders/object_storage.rb @@ -283,8 +283,9 @@ module ObjectStorage if file_storage? IO.copy_stream(path, file) else - streamer = lambda { |chunk, _, _| file.write(chunk) } - Excon.get(url, response_block: streamer) + Faraday.get(url) do |req| + req.options.on_data = proc { |chunk, _| file.write(chunk) } + end end file.seek(0, IO::SEEK_SET) |