MediaWiki  master
MediaWiki\User\Hook\UserAddGroupHook Interface Reference

This is a hook handler interface, see docs/Hooks.md. More...

Inheritance diagram for MediaWiki\User\Hook\UserAddGroupHook:

Public Member Functions

 onUserAddGroup ( $user, &$group, &$expiry)
 This hook is alled when adding a group or changing a group's expiry. More...
 

Detailed Description

This is a hook handler interface, see docs/Hooks.md.

Use the hook name "UserAddGroup" to register handlers implementing this interface.

Stable to implement

Definition at line 14 of file UserAddGroupHook.php.

Member Function Documentation

◆ onUserAddGroup()

MediaWiki\User\Hook\UserAddGroupHook::onUserAddGroup (   $user,
$group,
$expiry 
)

This hook is alled when adding a group or changing a group's expiry.

Since
1.35
Parameters
User$userThe user that is to have a group added
string&$groupThe group to add; can be modified
string | null&$expiryThe expiry time in TS_MW format, or null if the group is not to expire; can be modified
Returns
bool|void True or no return value to continue or false to abort (not add the group)

Implemented in MediaWiki\HookContainer\HookRunner.


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