lib/rocket_job/plugins/document.rb in rocketjob-3.0.0.beta3 vs lib/rocket_job/plugins/document.rb in rocketjob-3.0.0.rc1
- old
+ new
@@ -74,10 +74,10 @@
(fields.keys + embedded_relations.keys - doc.keys).each { |key| send("#{key}=", nil) }
@attributes = doc
apply_defaults
self
else
- raise Mongoid::Error::DocumentNotFound, "Document match #{_id.inspect} does not exist in #{collection.name} collection"
+ raise(Mongoid::Errors::DocumentNotFound.new(self.class, id))
end
end
end
end