lib/legato/management/profile.rb in legato-0.0.8 vs lib/legato/management/profile.rb in legato-0.0.9

- old
+ new

@@ -11,16 +11,19 @@ def path self.class.default_path + "/" + id.to_s end - attr_accessor :id, :name, :web_property_id, :user + attr_accessor :id, :name, :web_property_id, :user, :attributes def initialize(attributes, user) self.user = user self.id = attributes['id'] self.name = attributes['name'] self.web_property_id = attributes['webPropertyId'] + + ['id', 'name', 'webPropertyId'].each { |key| attributes.delete(key) } + self.attributes = attributes end def self.for_account(account) all(account.user, account.path+'/webproperties/~all/profiles') end