Sha256: 8839b8d5c2ccabfaf45a8523aad7a72b283bfe8a021e8afe4b398a380a5bbd58
Contents?: true
Size: 423 Bytes
Versions: 27
Compression:
Stored size: 423 Bytes
Contents
module Mongoid module Document # Returns all the embedded children in this document by recursion. # # @return [Array<Mongoid::Document>] # def embedded_children result = [] embedded_relations.each do |name, metadata| Array.wrap(send(name)).each do |child| result << child result += child.embedded_children end end result end end end
Version data entries
27 entries across 27 versions & 1 rubygems