Skip to content
Snippets Groups Projects
Commit 161ddb92 authored by Jess's avatar Jess
Browse files

Issue #1811892 by Mile23: Add missing type hinting to Statistics module docblocks

parent 0fa10c63
No related branches found
No related tags found
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
...@@ -125,10 +125,10 @@ function statistics_title_list($dbfield, $dbrows) { ...@@ -125,10 +125,10 @@ function statistics_title_list($dbfield, $dbrows) {
/** /**
* Retrieves a node's "view statistics". * Retrieves a node's "view statistics".
* *
* @param $nid * @param int $nid
* The node ID. * The node ID.
* *
* @return * @return array
* An associative array containing: * An associative array containing:
* - totalcount: Integer for the total number of times the node has been * - totalcount: Integer for the total number of times the node has been
* viewed. * viewed.
...@@ -148,7 +148,7 @@ function statistics_get($nid) { ...@@ -148,7 +148,7 @@ function statistics_get($nid) {
* Implements hook_ENTITY_TYPE_predelete() for node entities. * Implements hook_ENTITY_TYPE_predelete() for node entities.
*/ */
function statistics_node_predelete(EntityInterface $node) { function statistics_node_predelete(EntityInterface $node) {
// clean up statistics table when node is deleted // Clean up statistics table when node is deleted.
db_delete('node_counter') db_delete('node_counter')
->condition('nid', $node->id()) ->condition('nid', $node->id())
->execute(); ->execute();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment