MediaWiki REL1_35
MediaWiki\User\Hook\UserGetDefaultOptionsHook Interface Reference

Stable to implement. More...

Inheritance diagram for MediaWiki\User\Hook\UserGetDefaultOptionsHook:

Public Member Functions

 onUserGetDefaultOptions (&$defaultOptions)
 This hook is called after fetching core default user options but before returning the options.
 

Detailed Description

Stable to implement.

Definition at line 9 of file UserGetDefaultOptionsHook.php.

Member Function Documentation

◆ onUserGetDefaultOptions()

MediaWiki\User\Hook\UserGetDefaultOptionsHook::onUserGetDefaultOptions ( $defaultOptions)

This hook is called after fetching core default user options but before returning the options.

Warning: This hook is called for every call to User::getDefaultOptions(), which means it's potentially called dozens or hundreds of times. You may want to cache the results of non-trivial operations in your hook function for this reason.

Since
1.35
Parameters
array&$defaultOptionsArray of preference keys and their default values.
Returns
bool|void True or no return value to continue or false to abort

Implemented in MediaWiki\HookContainer\HookRunner.


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