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

more universal attribute handling

This commit is contained in:
geemus 2010-10-28 10:55:35 -07:00
parent c8821907bb
commit 5fddabd891

View file

@ -140,7 +140,7 @@ module Fog
unless self.class.ignored_attributes.include?(key)
if aliased_key = self.class.aliases[key]
send("#{aliased_key}=", value)
elsif (self.class.attributes | [:collection, :connection]).include?(key.to_sym)
elsif respond_to?("#{key}=")
send("#{key}=", value)
else
attributes.merge!(key => value)