Module: Mongoid::Criteria::Queryable::Extensions::Array::ClassMethods
- Defined in:
- lib/mongoid/criteria/queryable/extensions/array.rb
Instance Method Summary collapse
-
#evolve(object) ⇒ Object
Evolve the object when the serializer is defined as an array.
Instance Method Details
#evolve(object) ⇒ Object
Evolve the object when the serializer is defined as an array.
147 148 149 150 151 152 153 |
# File 'lib/mongoid/criteria/queryable/extensions/array.rb', line 147 def evolve(object) if object.is_a?(::Array) object.map { |obj| obj.class.evolve(obj) } else object end end |