embed :objects is the default

A commit with an integration test that covers this functionality is
coming after this one
This commit is contained in:
Santiago Pastorino 2013-10-10 19:44:14 -02:00
parent 4f70dc2091
commit 4b91d0e5ec

View File

@ -8,7 +8,7 @@ module ActiveModel
@name = name.to_s
@options = options
self.embed = options[:embed] || SETTINGS[:embed]
self.embed = options[:embed] || SETTINGS[:embed] || :objects
@embed_in_root = @embed_ids && (options[:include] || SETTINGS[:include])
@embed_key = options[:embed_key] || :id
@key = options[:key]