Index: trunk/extensions/TitleBlacklist/TitleBlacklist.list.php |
— | — | @@ -28,7 +28,6 @@ |
29 | 29 | //Try to find something in the cache |
30 | 30 | $cachedBlacklist = $wgMemc->get( wfMemcKey( "title_blacklist_entries" ) ); |
31 | 31 | if( is_array( $cachedBlacklist ) && count( $cachedBlacklist ) > 0 && ( $cachedBlacklist[0]->getFormatVersion() == self::VERSION ) ) { |
32 | | - |
33 | 32 | $this->mBlacklist = $cachedBlacklist; |
34 | 33 | wfProfileOut( __METHOD__ ); |
35 | 34 | return; |
— | — | @@ -147,7 +146,7 @@ |
148 | 147 | } |
149 | 148 | |
150 | 149 | /** |
151 | | - * Check whether the blacklist restricts |
| 150 | + * Check whether the blacklist restricts |
152 | 151 | * performing a specific action on the given Title |
153 | 152 | * |
154 | 153 | * @param $title Title to check |
— | — | @@ -161,7 +160,7 @@ |
162 | 161 | } |
163 | 162 | $blacklist = $this->getBlacklist(); |
164 | 163 | foreach ( $blacklist as $item ) { |
165 | | - if( !$item->matches( $title, $action ) ) { |
| 164 | + if( $item->matches( $title, $action ) ) { |
166 | 165 | if( $this->isWhitelisted( $title, $action ) ) { |
167 | 166 | return false; |
168 | 167 | } |
— | — | @@ -170,9 +169,9 @@ |
171 | 170 | } |
172 | 171 | return false; |
173 | 172 | } |
174 | | - |
| 173 | + |
175 | 174 | /** |
176 | | - * Check whether it has been explicitly whitelisted that the |
| 175 | + * Check whether it has been explicitly whitelisted that the |
177 | 176 | * current User may perform a specific action on the given Title |
178 | 177 | * |
179 | 178 | * @param $title Title to check |
— | — | @@ -191,7 +190,7 @@ |
192 | 191 | } |
193 | 192 | return false; |
194 | 193 | } |
195 | | - |
| 194 | + |
196 | 195 | /** |
197 | 196 | * Get the current blacklist |
198 | 197 | * |
— | — | @@ -203,7 +202,7 @@ |
204 | 203 | } |
205 | 204 | return $this->mBlacklist; |
206 | 205 | } |
207 | | - |
| 206 | + |
208 | 207 | /* |
209 | 208 | * Get the current whitelist |
210 | 209 | * |
— | — | @@ -215,7 +214,7 @@ |
216 | 215 | } |
217 | 216 | return $this->mWhitelist; |
218 | 217 | } |
219 | | - |
| 218 | + |
220 | 219 | /** |
221 | 220 | * Get the text of a blacklist source via HTTP |
222 | 221 | * |
— | — | @@ -235,7 +234,7 @@ |
236 | 235 | } |
237 | 236 | return $result; |
238 | 237 | } |
239 | | - |
| 238 | + |
240 | 239 | /** |
241 | 240 | * Invalidate the blacklist cache |
242 | 241 | */ |
— | — | @@ -261,7 +260,7 @@ |
262 | 261 | } |
263 | 262 | return $badEntries; |
264 | 263 | } |
265 | | - |
| 264 | + |
266 | 265 | /** |
267 | 266 | * Inidcates whether user can override blacklist on certain action. |
268 | 267 | * |