It seems protected_attributes is preventing creating multiple records using an array. ie
class Foo < ActiveRecord::Base
attr_accesssible :bar
end
Foo.new({bar: 'baz'}) # => works
Foo.new([{bar: 'baz'},{bar: 'boo'}]) # => throws an error
The error I get is
undefined method `stringify_keys' for #<Array:0x007faa7d6c76c0>
in gems/protected_attributes-1.0.8/lib/active_record/mass_assignment_security/attribute_assignment.rb:51:in `assign_attributes'
As far as I can tell this method of initializing multiple objects is officially supported in the Rails docs
It seems
protected_attributes
is preventing creating multiple records using an array. ieThe error I get is
As far as I can tell this method of initializing multiple objects is officially supported in the Rails docs