diff --git a/lib/fog/aws/requests/storage/sync_clock.rb b/lib/fog/aws/requests/storage/sync_clock.rb index a67ee303b..147c5b8b8 100644 --- a/lib/fog/aws/requests/storage/sync_clock.rb +++ b/lib/fog/aws/requests/storage/sync_clock.rb @@ -8,8 +8,8 @@ module Fog def sync_clock response = begin get_service - rescue => error - error.respond_to(:response) ? error.response : error.message + rescue Excon::Errors::HTTPStatusError => error + error.response end Fog::Time.now = Time.parse(response.headers['Date']) end