mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/AbuseFilter.git
synced 2024-11-15 02:03:53 +00:00
2bdb44d58b
As for all mostly unused consequences, blockautopromote has a couple of major problems: first, it blocked the status for a random time between 3 and 7 days, which to me makes no sense at all (is it some sort of casino?), and this patch fixes it to 5 days. Second, nothing was logged, not the blocking nor the unblocking. Here I'm adding a LogHandler for two new sub-actions of 'rights' to keep track of both action. Bug: T49412 Change-Id: If48a48f5b8baaf9e77c0826466f5d03bb7f691d0
16 lines
336 B
PHP
16 lines
336 B
PHP
<?php
|
|
|
|
class AbuseFilterRightsLogFormatter extends LogFormatter {
|
|
|
|
/**
|
|
* @return string
|
|
*/
|
|
protected function getMessageKey() {
|
|
$subtype = $this->entry->getSubtype();
|
|
// Messages that can be used here:
|
|
// * logentry-rights-blockautopromote
|
|
// * logentry-rights-restoreautopromote
|
|
return "logentry-rights-$subtype";
|
|
}
|
|
}
|