function hook_comment_update

Respond to updates to a comment.

Parameters

Drupal\comment\Comment $comment: The comment object.

Related topics

4 functions implement hook_comment_update()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

entity_crud_hook_test_comment_update in drupal/core/modules/system/tests/modules/entity_crud_hook_test/entity_crud_hook_test.module
Implements hook_comment_update().
forum_comment_update in drupal/core/modules/forum/forum.module
Implements hook_comment_update().
search_comment_update in drupal/core/modules/search/search.module
Implements hook_comment_update().
tracker_comment_update in drupal/core/modules/tracker/tracker.module
Implements hook_comment_update().

File

drupal/core/modules/comment/comment.api.php, line 46
Hooks provided by the Comment module.

Code

function hook_comment_update(Drupal\comment\Comment $comment) {

  // Reindex the node when comments are updated.
  search_touch_node($comment->nid);
}