MediaWiki  master
MediaWiki\User\Hook\UserRetrieveNewTalksHook Interface Reference
Inheritance diagram for MediaWiki\User\Hook\UserRetrieveNewTalksHook:

Public Member Functions

 onUserRetrieveNewTalks ( $user, &$talks)
 This hook is called when retrieving "You have new messages!" message(s). More...

Detailed Description

since 1.35

Definition at line 11 of file UserRetrieveNewTalksHook.php.

Member Function Documentation

◆ onUserRetrieveNewTalks()

MediaWiki\User\Hook\UserRetrieveNewTalksHook::onUserRetrieveNewTalks (   $user,

This hook is called when retrieving "You have new messages!" message(s).

To override the notification, populate the $talks array and then return false. If the hook returns true, $talks will not be used.

User$userUser retrieving new talks messages
array[]&$talksArray in which each element is an associative array describing a notification, with the following keys:
  • wiki: The database name of the wiki
  • link: Root-relative link to the user's talk page
  • rev: The last talk page revision that the user has seen or null. This is useful for building diff links.
bool|void False to use $talks, true or no return value to continue

Implemented in MediaWiki\HookContainer\HookRunner.

The documentation for this interface was generated from the following file: