Extension:AbuseFilter/Hooks/AbuseFilter-generateUserVars

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-generateUserVars
Available from version ??? (Gerrit change 80152)
Allows altering the variables generated for a specific user
Define function:
public static function onAbuseFilter_generateUserVars( MediaWiki\Extension\AbuseFilter\Variables\VariableHolder $vars, User $user, ?RecentChange $rc ) { ... }
Attach hook:
$wgHooks['AbuseFilter-generateUserVars'][] = 'MyExtensionHooks::onAbuseFilter_generateUserVars';
Called from:File(s): AbuseFilter / VariableGenerator.php

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

Arguments

  • $vars AbuseFilterVariableHolder object to add vars to
  • $user User object
  • $rc If the variables should be generated for an RC entry, this is the entry. Null if it's for the current action being filtered.