diff --git a/CHANGELOG.md b/CHANGELOG.md index 37da1f5..5bb7afb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,7 +4,7 @@ ##### Enhancements -* Add User-Agent to `cURL` requests when downloading source via the `:http` download strategy, unless one was provided by the `:headers` option. +* Add User-Agent to `cURL` requests when downloading source via the `:http` download strategy, unless one was provided by the `:headers` option. [Sean Reinhardt](https://github.com/seanreinhardtapps) [#9619](https://github.com/CocoaPods/CocoaPods/issues/9619) diff --git a/lib/cocoapods-downloader/base.rb b/lib/cocoapods-downloader/base.rb index 8f9aba3..91b198d 100644 --- a/lib/cocoapods-downloader/base.rb +++ b/lib/cocoapods-downloader/base.rb @@ -129,7 +129,7 @@ def checkout_options # @return [String] the User-Agent string. # def self.user_agent_string(base_module = Pod) - pods_version = base_module.const_defined?("VERSION") ? "CocoaPods/#{base_module::VERSION};" : '' + pods_version = base_module.const_defined?("VERSION") ? "CocoaPods/#{base_module::VERSION} " : '' "#{pods_version}cocoapods-downloader/#{Pod::Downloader::VERSION}" end diff --git a/spec/base_spec.rb b/spec/base_spec.rb index de34ec8..f2128b9 100644 --- a/spec/base_spec.rb +++ b/spec/base_spec.rb @@ -27,7 +27,7 @@ module TestModuleNoVersion module TestModuleWithVersion VERSION = 'a.b.c'.freeze end - Base.user_agent_string(TestModuleWithVersion).should == "CocoaPods/#{TestModuleWithVersion::VERSION};cocoapods-downloader/#{Pod::Downloader::VERSION}" + Base.user_agent_string(TestModuleWithVersion).should == "CocoaPods/#{TestModuleWithVersion::VERSION} cocoapods-downloader/#{Pod::Downloader::VERSION}" end end end