Identity map + carrierwave-mongoid problem #58

Merged
merged 1 commit into from Sep 24, 2012
Jump to file or symbol
Failed to load files and symbols.
+1 −1
Split
@@ -56,7 +56,7 @@ def find_previous_model_for_#{column}
association = ancestors.inject(reloaded_parent) { |parent,(key,ancestor)| (parent.is_a?(Array) ? parent.find(ancestor.to_key.first) : parent).send(key) }
association.is_a?(Array) ? association.find(to_key.first) : association
else
- self.class.unscoped.find(to_key.first)
+ self.class.unscoped.for_ids(to_key.first).first
end
end