mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
Fix sync_clock method, only rescue Excon::Errors::HTTPStatusError that are known to have a #response method, let all other exceptions bubble up
This commit is contained in:
parent
2a4abcd092
commit
c88b16a008
1 changed files with 2 additions and 2 deletions
|
@ -8,8 +8,8 @@ module Fog
|
||||||
def sync_clock
|
def sync_clock
|
||||||
response = begin
|
response = begin
|
||||||
get_service
|
get_service
|
||||||
rescue => error
|
rescue Excon::Errors::HTTPStatusError => error
|
||||||
error.respond_to(:response) ? error.response : error.message
|
error.response
|
||||||
end
|
end
|
||||||
Fog::Time.now = Time.parse(response.headers['Date'])
|
Fog::Time.now = Time.parse(response.headers['Date'])
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue