1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00

Revert "Updated gem spec to require json rather than multi_json"

This reverts commits: 66638b25d7,
3f0314dbd1, and
18ce4b7eca.

Since google-api-client was added as a dependency in afa9b025e9,
multi_json is a de facto dependency of fog, so this is a needless layer.
If #1034 is still an issue, I'd be happy to ship a version of multi_json
that requires rubygems >= 1.3.5.
This commit is contained in:
Erik Michaels-Ober 2013-05-05 11:38:54 -07:00
parent ca945a0432
commit f2bd2404d1
38 changed files with 61 additions and 152 deletions

View file

@ -47,6 +47,8 @@ module Fog
class Real
def initialize(options={})
require 'multi_json'
@dreamhost_api_key = options[:dreamhost_api_key]
if options[:dreamhost_url]
uri = URI.parse(options[:dreamhost_url])
@ -71,7 +73,7 @@ module Fog
response = @connection.request(params)
unless response.body.empty?
response.body = Fog::JSON.decode(response.body)
response.body = MultiJson.decode(response.body)
end
if response.body['result'] != 'success'
raise response.body['data']