mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/AbuseFilter.git
synced 2024-11-23 21:53:35 +00:00
Fix caller name in AbuseFilterHooks::fetchAllTags
Seeing {closure} in the logs as caller is not helpful Change-Id: Id3bf5c7fd810d48dc04a167692b336b3ccba2eb4
This commit is contained in:
parent
4fdd1bbf20
commit
45e6fa932d
|
@ -414,6 +414,7 @@ class AbuseFilterHooks {
|
|||
private static function fetchAllTags( array &$tags, $enabled ) {
|
||||
$services = MediaWikiServices::getInstance();
|
||||
$cache = $services->getMainWANObjectCache();
|
||||
$fname = __METHOD__;
|
||||
|
||||
$tags = $cache->getWithSetCallback(
|
||||
// Key to store the cached value under
|
||||
|
@ -423,7 +424,7 @@ class AbuseFilterHooks {
|
|||
$cache::TTL_MINUTE,
|
||||
|
||||
// Function that derives the new key value
|
||||
function ( $oldValue, &$ttl, array &$setOpts ) use ( $enabled, $tags ) {
|
||||
function ( $oldValue, &$ttl, array &$setOpts ) use ( $enabled, $tags, $fname ) {
|
||||
global $wgAbuseFilterCentralDB, $wgAbuseFilterIsCentral;
|
||||
|
||||
$dbr = wfGetDB( DB_REPLICA );
|
||||
|
@ -440,7 +441,7 @@ class AbuseFilterHooks {
|
|||
[ 'abuse_filter_action', 'abuse_filter' ],
|
||||
'afa_parameters',
|
||||
$where,
|
||||
__METHOD__,
|
||||
$fname,
|
||||
[],
|
||||
[ 'abuse_filter' => [ 'INNER JOIN', 'afa_filter=af_id' ] ]
|
||||
);
|
||||
|
@ -458,7 +459,7 @@ class AbuseFilterHooks {
|
|||
[ 'abuse_filter_action', 'abuse_filter' ],
|
||||
'afa_parameters',
|
||||
$where,
|
||||
__METHOD__,
|
||||
$fname,
|
||||
[],
|
||||
[ 'abuse_filter' => [ 'INNER JOIN', 'afa_filter=af_id' ] ]
|
||||
);
|
||||
|
|
Loading…
Reference in a new issue