lib/shamu/attributes.rb in shamu-0.0.9 vs lib/shamu/attributes.rb in shamu-0.0.11

- old
+ new

@@ -119,10 +119,12 @@ if attributes.respond_to?( :to_attributes ) attributes.to_attributes # Allow protected attributes to be used without explicitly being set. # All 'Attributes' classes are them selves the explicit set of permitted # attributes. + elsif attributes.respond_to?( :to_unsafe_h ) + attributes.to_unsafe_h elsif attributes.respond_to?( :to_hash ) attributes.to_hash.symbolize_keys elsif attributes.respond_to?( :to_h ) attributes.to_h.symbolize_keys else @@ -268,6 +270,6 @@ end end end -end \ No newline at end of file +end