Extension:AbuseFilter/Hooks/AbuseFilter-filterAction

From Linux Web Expert

The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
AbuseFilter-filterAction
Available from version 1.19.0
Allows overwriting of variables in AbuseFilter::filterAction() just before they're checked against filters.
Define function:
public static function onAbuseFilter_filterAction( MediaWiki\Extension\AbuseFilter\Variables\VariableHolder $vars, MediaWiki\Title\Title $title ) { ... }
Attach hook:
$wgHooks['AbuseFilter-filterAction'][] = 'MyExtensionHooks::onAbuseFilter_filterAction';
Called from:File(s): AbuseFilter / includes/AbuseFilterRunner.php
Function(s): init

For more information about attaching hooks, see Manual:Hooks .
For examples of other extensions using this hook, see Category:AbuseFilter-filterAction extensions.

Note that you may specify custom variables in a saner way using other hooks:

Parameters

  • $vars: AbuseFilterVariableHolder with variables
  • $title: Title object