public function Simple::onQueuePostDelete in Entityqueue 8
Acts on deleted entity queues before the delete hook is invoked.
Parameters
\Drupal\entityqueue\EntityQueueInterface $queue: The entity queue object.
\Drupal\Core\Entity\EntityStorageInterface $storage: The entity storage object.
Overrides EntityQueueHandlerBase::onQueuePostDelete
File
- src/
Plugin/ EntityQueueHandler/ Simple.php, line 140
Class
- Simple
- Defines an entity queue handler that manages a single subqueue.
Namespace
Drupal\entityqueue\Plugin\EntityQueueHandlerCode
public function onQueuePostDelete(EntityQueueInterface $queue, EntityStorageInterface $storage) {
// Delete the subqueue when the parent queue is deleted.
if ($subqueue = EntitySubqueue::load($queue
->id())) {
$subqueue
->delete();
}
}