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

fixed bug whereby record.save() created a new record rather than updating the existing record

This commit is contained in:
Ijonas Kisselbach 2011-03-10 08:19:07 +08:00 committed by Wesley Beary
parent 9d4bfa3533
commit 8cd9c1ec4b

View file

@ -36,7 +36,10 @@ module Fog
options = {}
options[:prio] = priority if priority
options[:ttl] = ttl if ttl
data = connection.create_record(zone.domain, name, type, ip, options)
options[:name] = name if name
options[:content] = ip if ip
options[:type] = type if type
data = connection.update_record(zone.domain, id, options)
merge_attributes(data.body["record"])
true
end