lib/fog/rackspace/models/load_balancers/virtual_ip.rb in fog-maestrodev-1.7.0.20121114190951 vs lib/fog/rackspace/models/load_balancers/virtual_ip.rb in fog-maestrodev-1.8.0.20130109172219
- old
+ new
@@ -11,17 +11,17 @@
attribute :type
attribute :ip_version, :aliases => 'ipVersion'
def destroy
requires :identity, :load_balancer
- connection.delete_virtual_ip(load_balancer.identity, identity)
+ service.delete_virtual_ip(load_balancer.identity, identity)
true
end
def save
- raise Fog::Errors::Error.new('Resaving an existing object may create a duplicate') if identity
+ raise Fog::Errors::Error.new('Resaving an existing object may create a duplicate') if persisted?
requires :load_balancer, :type
- data = connection.create_virtual_ip(load_balancer.id, type)
+ data = service.create_virtual_ip(load_balancer.id, type)
merge_attributes(data.body)
true
end
private