Manual:Hooks/PermissionErrorAudit
Appearance
Deprecated: This feature is deprecated and should no longer be used, however it is possibly still available for reasons of backwards compatibility. This feature was deprecated in version 1.44.0. See PermissionStatusAudit for an alternative way to use this feature. |
| PermissionErrorAudit | |
|---|---|
| Available from version 1.39.0 (Gerrit change 802483) Called after permission checks to allow logging. | |
| Define function: | public static function onPermissionErrorAudit(
MediaWiki\Linker\LinkTarget $title,
MediaWiki\User\UserIdentity $user,
string $action,
string $rigor,
array $errors
) { ... }
|
| Attach hook: | In extension.json:
{
"Hooks": {
"PermissionErrorAudit": "MediaWiki\\Extension\\MyExtension\\Hooks::onPermissionErrorAudit"
}
}
|
| Called from: | File(s): Permissions/PermissionManager.php Function(s): getPermissionErrorsInternal |
| Interface: | PermissionErrorAuditHook.php |
For more information about attaching hooks, see Manual:Hooks.
For examples of extensions using this hook, see Category:PermissionErrorAudit extensions.
Details
[edit]$title: Page in question$user: User to check$action: Action being checked$rigor: One ofPermissionManager::RIGOR_constants$errors: Array of arrays of the arguments towfMessage()to explain permissions problems.
Cannot be aborted.