You are here

nodeviewcount_hooks_test.module in Node view count 8

Support module for nodeviewcount hooks testing.

File

tests/modules/nodeviewcount_hooks_test/nodeviewcount_hooks_test.module
View source
<?php

/**
 * @file
 * Support module for nodeviewcount hooks testing.
 */
use Drupal\node\NodeInterface;

/**
 * Implements hook_nodeviewcount_insert().
 */
function nodeviewcount_hooks_test_nodeviewcount_insert(NodeInterface $node, $view_mode) {
  \Drupal::logger('nodeviewcount')
    ->notice($node
    ->getTitle());
}