mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/AbuseFilter.git
synced 2024-11-24 14:13:54 +00:00
0f7f4ad917
Bug: T178007 Change-Id: Ia1ae78b30b889b7a8965354ae0a404bf9a520917
50 lines
985 B
PHP
50 lines
985 B
PHP
<?php
|
|
|
|
class AbuseFilterModifyLogFormatter extends LogFormatter {
|
|
|
|
/**
|
|
* @return string
|
|
*/
|
|
protected function getMessageKey() {
|
|
return 'abusefilter-logentry-modify';
|
|
}
|
|
|
|
/**
|
|
* @return array
|
|
*/
|
|
protected function extractParameters() {
|
|
$parameters = $this->entry->getParameters();
|
|
if ( $this->entry->isLegacy() ) {
|
|
list( $historyId, $filterId ) = $parameters;
|
|
} else {
|
|
$historyId = $parameters['historyId'];
|
|
$filterId = $parameters['newId'];
|
|
}
|
|
|
|
$detailsTitle = SpecialPage::getTitleFor(
|
|
'AbuseFilter',
|
|
"history/$filterId/diff/prev/$historyId"
|
|
);
|
|
|
|
$params = [];
|
|
$params[3] = Message::rawParam(
|
|
$this->makePageLink(
|
|
$this->entry->getTarget(),
|
|
[],
|
|
$this->msg( 'abusefilter-log-detailedentry-local' )
|
|
->numParams( $filterId )->escaped()
|
|
)
|
|
);
|
|
$params[4] = Message::rawParam(
|
|
$this->makePageLink(
|
|
$detailsTitle,
|
|
[],
|
|
$this->msg( 'abusefilter-log-detailslink' )->escaped()
|
|
)
|
|
);
|
|
|
|
return $params;
|
|
}
|
|
|
|
}
|