public function MongoDBQueue::deleteItem in MongoDB 7
Delete a finished item from the queue.
Parameters
object $item: The item to delete.
Throws
\MongoConnectionException
\MongoCursorException
\MongoCursorTimeoutException
Overrides DrupalQueueInterface::deleteItem
File
- mongodb_queue/
mongodb_queue.inc, line 129 - Contains \MongoDBQueue.
Class
Code
public function deleteItem($item) {
mongodb_collection($this->collection)
->remove(array(
'_id' => $item->_id,
), mongodb_default_write_options());
}