railsthemes 2.0.2 → 2.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -87,7 +87,7 @@ module Railsthemes
|
|
87
87
|
install_from_file_system File.join(tempdir, 'rt-archive')
|
88
88
|
end
|
89
89
|
else
|
90
|
-
Safe.log_and_abort "We didn't recognize the code you gave to download the theme (#{code})
|
90
|
+
Safe.log_and_abort "We didn't recognize the code you gave to download the theme (#{code}).\n" +
|
91
91
|
"It should look something like your@email.com:ABCDEF."
|
92
92
|
end
|
93
93
|
end
|
@@ -110,7 +110,8 @@ module Railsthemes
|
|
110
110
|
if response.code.to_s == '200'
|
111
111
|
response.body
|
112
112
|
else
|
113
|
-
logger.debug "download_url response code: #{response
|
113
|
+
logger.debug "download_url response code: #{response[:code]}"
|
114
|
+
nil
|
114
115
|
end
|
115
116
|
end
|
116
117
|
end
|
data/lib/railsthemes/version.rb
CHANGED
@@ -233,8 +233,8 @@ describe Railsthemes::Installer do
|
|
233
233
|
it 'should return nil when cannot download' do
|
234
234
|
stub(Railsthemes::Utils).get_primary_configuration { [] }
|
235
235
|
FakeWeb.register_uri :get,
|
236
|
-
'https://railsthemes.com/download?code=panozzaj@gmail.com:code&config=',
|
237
|
-
:body => '', :status => ['401', 'Unauthorized']
|
236
|
+
'https://railsthemes.com/download?code=panozzaj@gmail.com:code&config=&v=2',
|
237
|
+
:body => 'Unauthorized', :status => ['401', 'Unauthorized']
|
238
238
|
result = @installer.get_download_url 'panozzaj@gmail.com:code'
|
239
239
|
result.should == nil
|
240
240
|
end
|