lib/fog/storm_on_demand/shared.rb in fog-1.22.0 vs lib/fog/storm_on_demand/shared.rb in fog-1.22.1

- old
+ new

@@ -1,9 +1,8 @@ module Fog module StormOnDemand module RealShared - API_URL = 'https://api.stormondemand.com' API_VERSION = 'v1' def initialize(options={}) uri = URI.parse(options[:storm_on_demand_auth_url] ||= API_URL) @@ -42,10 +41,10 @@ end end unless response.body.empty? response.body = Fog::JSON.decode(response.body) end - if response.body.has_key?('error_class') + if response.body.key?('error_class') raise(Fog::Compute::StormOnDemand::Error, response.body.inspect) end response end end