r68296 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r68295‎ | r68296 | r68297 >
Date:00:53, 20 June 2010
Author:nad
Status:deferred
Tags:
Comment:
no need to define info array in onUserGetRights now, done in class def
Modified paths:
  • /trunk/extensions/SimpleSecurity/SimpleSecurity.php (modified) (history)
  • /trunk/extensions/SimpleSecurity/SimpleSecurity_body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SimpleSecurity/SimpleSecurity_body.php
@@ -6,7 +6,11 @@
77
88 var $guid = '';
99 var $cache = array();
10 - var $info = array( 'LS' => array(), 'PR' => array(), 'CR' => array() );
 10+ var $info = array(
 11+ 'LS' => array(), # security info for rules from LocalSettings ($wgPageRestrictions)
 12+ 'PR' => array(), # security info for rules from protect tab
 13+ 'CR' => array() # security info for rules which are currently in effect
 14+ );
1115
1216 function __construct() {
1317 global $wgParser, $wgHooks, $wgLogTypes, $wgLogNames, $wgLogHeaders, $wgLogActions, $wgMessageCache,
@@ -180,9 +184,6 @@
181185 }
182186 if ( !is_object( $title ) ) return true; # If still no usable title bail
183187
184 - $this->info['LS'] = array(); # security info for rules from LocalSettings ($wgPageRestrictions)
185 - $this->info['PR'] = array(); # security info for rules from protect tab
186 - $this->info['CR'] = array(); # security info for rules which are currently in effect
187188 $groups = $user->getEffectiveGroups();
188189
189190 # Put the anon read right back in $wgGroupPermissions if it was there initially
Index: trunk/extensions/SimpleSecurity/SimpleSecurity.php
@@ -20,7 +20,7 @@
2121 */
2222
2323 if ( !defined( 'MEDIAWIKI' ) ) die( 'Not an entry point.' );
24 -if ( version_compare( $wgVersion, '1.12.0' ) < 0 ) die( 'Sorry, this extension requires at least MediaWiki version 1.12.0' );
 24+if ( version_compare( $wgVersion, '1.12.1' ) < 0 ) die( 'Sorry, this extension requires at least MediaWiki version 1.12.0' );
2525
2626 define( 'SIMPLESECURITY_VERSION', '4.4.1, 2010-06-12' );
2727

Status & tagging log