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

[rackspace|dns] Adapted to changes in callback mechanism

This commit is contained in:
Brian Hartsock 2011-11-10 20:53:00 -05:00
parent ef9fae38d6
commit 34ee799ee7
3 changed files with 3 additions and 3 deletions

View file

@ -11,7 +11,7 @@ module Fog
response = nil
Fog.wait_for(timeout, interval) do
response = connection.callback job_id
if response.status != 202
if response.body['status'] != 'RUNNING'
true
elsif retries == 0
raise Fog::Errors::Error.new("Wait on job #{job_id} took too long")

View file

@ -51,7 +51,7 @@ module Fog
}
response = wait_for_job connection.add_records(@zone.identity, [options]).body['jobId']
merge_attributes(response.body['request']['records'].select {|record| record['name'] == self.name && record['type'] == self.type && record['value'] == self.value})
merge_attributes(response.body['response']['records'].select {|record| record['name'] == self.name && record['type'] == self.type && record['data'] == self.value}.first)
true
end

View file

@ -52,7 +52,7 @@ module Fog
response = connection.create_domains([data])
response = wait_for_job response.body['jobId']
merge_attributes(response.body['request']['domains'].select {|domain| domain['name'] == self.domain})
merge_attributes(response.body['response']['domains'].select {|domain| domain['name'] == self.domain}.first)
end
def update