Index: trunk/extensions/AbuseFilter/AbuseFilter.class.php |
— | — | @@ -118,16 +118,21 @@ |
119 | 119 | ); |
120 | 120 | |
121 | 121 | public static function addNavigationLinks( $out, $sk, $pageType ) { |
122 | | - global $wgLang; |
| 122 | + global $wgLang, $wgUser; |
123 | 123 | $linkDefs = array( |
124 | 124 | 'home' => 'Special:AbuseFilter', |
125 | 125 | 'recentchanges' => 'Special:AbuseFilter/history', |
126 | 126 | 'test' => 'Special:AbuseFilter/test', |
127 | 127 | 'examine' => 'Special:AbuseFilter/examine', |
128 | 128 | 'log' => 'Special:AbuseLog', |
| 129 | + ); |
| 130 | + |
| 131 | + if ($wgUser->isAllowed( 'abusefilter-modify' ) ) { |
| 132 | + $linkDefs = array_merge( $linkDefs, array( |
129 | 133 | 'tools' => 'Special:AbuseFilter/tools', |
130 | 134 | 'import' => 'Special:AbuseFilter/import', |
131 | | - ); |
| 135 | + ) ); |
| 136 | + } |
132 | 137 | |
133 | 138 | // Save some translator work |
134 | 139 | $msgOverrides = array( |