Class: Mongoid::Commands::Delete
- Defined in:
- lib/mongoid/commands/delete.rb
Class Method Summary collapse
-
.execute(doc) ⇒ Object
Performs a delete of the supplied
Document
without any callbacks.
Class Method Details
.execute(doc) ⇒ Object
Performs a delete of the supplied Document
without any callbacks.
Options:
doc: A new Document
that is going to be deleted.
10 11 12 |
# File 'lib/mongoid/commands/delete.rb', line 10 def self.execute(doc) doc.collection.remove(:_id => doc.id) end |