function node_revision_delete in Drupal 9
Same name and namespace in other branches
- 8 core/modules/node/node.module \node_revision_delete()
- 4 modules/node.module \node_revision_delete()
- 5 modules/node/node.module \node_revision_delete()
- 7 modules/node/node.module \node_revision_delete()
Deletes a node revision.
Parameters
int $revision_id: The revision ID to delete.
1 call to node_revision_delete()
- node_user_predelete in core/
modules/ node/ node.module - Implements hook_ENTITY_TYPE_predelete() for user entities.
File
- core/
modules/ node/ node.module, line 359 - The core module that allows content to be submitted to the site.
Code
function node_revision_delete($revision_id) {
\Drupal::entityTypeManager()
->getStorage('node')
->deleteRevision($revision_id);
}