lib/collector/repository.rb in collector-0.0.12 vs lib/collector/repository.rb in collector-0.0.13

- old
+ new

@@ -58,10 +58,12 @@ deserialize!(document) end end def find_by_id(id) - deserialize!(collection.find(_id: id)) + collection.find(_id: id).map do |document| + deserialize!(document) + end end def method_missing(method_sym, *arguments, &block) if method_sym.to_s =~ /^find_by_(.*)$/ collection.find($1.to_sym => arguments.first).map do |document|