diff --git a/Library/Homebrew/test/cask/download_strategy_spec.rb b/Library/Homebrew/test/cask/download_strategy_spec.rb index 60d101bdb8..17da1e36e4 100644 --- a/Library/Homebrew/test/cask/download_strategy_spec.rb +++ b/Library/Homebrew/test/cask/download_strategy_spec.rb @@ -26,11 +26,11 @@ describe "download strategies", :cask do downloader.fetch expect(downloader).to have_received(:curl).with( - cask.url.to_s, "--location", "--remote-time", "--continue-at", "-", "--output", kind_of(Pathname), + cask.url.to_s, user_agent: :default ) end diff --git a/Library/Homebrew/utils/curl.rb b/Library/Homebrew/utils/curl.rb index 6aaf9be0cb..9f0d8f75d6 100644 --- a/Library/Homebrew/utils/curl.rb +++ b/Library/Homebrew/utils/curl.rb @@ -38,7 +38,7 @@ def curl(*args) end def curl_download(*args, to: nil, **options) - curl(*args, "--location", "--remote-time", "--continue-at", "-", "--output", to, **options) + curl("--location", "--remote-time", "--continue-at", "-", "--output", to, *args, **options) end def curl_output(*args, **options)