You are here

public function ForumIndexStorage::delete in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/forum/src/ForumIndexStorage.php \Drupal\forum\ForumIndexStorage::delete()

Deletes the records in {forum} table for the given node.

Parameters

\Drupal\node\NodeInterface $node: The node for which the records are to be deleted.

Overrides ForumIndexStorageInterface::delete

File

core/modules/forum/src/ForumIndexStorage.php, line 68
Contains \Drupal\forum\ForumIndexStorage.

Class

ForumIndexStorage
Handles CRUD operations to {forum_index} table.

Namespace

Drupal\forum

Code

public function delete(NodeInterface $node) {
  $this->database
    ->delete('forum')
    ->condition('nid', $node
    ->id())
    ->execute();
}