Check whether user is allowed to see the hit count

Bug: T120562
Change-Id: I464fc4806b52327a58fddb54404f5869c8431194
This commit is contained in:
Matěj Suchánek 2016-11-14 14:04:31 +00:00
parent 18d29ccc05
commit 3e6605c94b

View file

@ -372,7 +372,7 @@ class AbuseFilterViewEdit extends AbuseFilterView {
}
// Hit count display
if ( !empty( $row->af_hit_count ) ) {
if ( !empty( $row->af_hit_count ) && $user->isAllowed( 'abusefilter-log-detail' ) ) {
$count_display = $this->msg( 'abusefilter-hitcount' )
->numParams( (int) $row->af_hit_count )->text();
$hitCount = $this->linkRenderer->makeKnownLink(