mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/AbuseFilter.git
synced 2024-11-23 13:46:48 +00:00
Use a local variable for hitcount in AbuseFilterViewEdit
Assist static code analyzer that null is not passed to Message::numParams Change-Id: Ic0369493b274de3379067745573e1f8baed56dcb
This commit is contained in:
parent
63de22357d
commit
a02fe0a2dd
|
@ -373,9 +373,10 @@ class AbuseFilterViewEdit extends AbuseFilterView {
|
|||
}
|
||||
|
||||
// Hit count display
|
||||
if ( $filterObj->getHitCount() !== null && $this->afPermManager->canSeeLogDetails( $user ) ) {
|
||||
$hitCount = $filterObj->getHitCount();
|
||||
if ( $hitCount !== null && $this->afPermManager->canSeeLogDetails( $user ) ) {
|
||||
$count_display = $this->msg( 'abusefilter-hitcount' )
|
||||
->numParams( $filterObj->getHitCount() )->text();
|
||||
->numParams( $hitCount )->text();
|
||||
$hitCount = $this->linkRenderer->makeKnownLink(
|
||||
SpecialPage::getTitleFor( 'AbuseLog' ),
|
||||
$count_display,
|
||||
|
|
Loading…
Reference in a new issue