Index: trunk/extensions/FlaggedRevs/FlaggedRevs.php |
— | — | @@ -145,16 +145,19 @@ |
146 | 146 | # 0 => sighted; 1 => quality; 2 => pristine |
147 | 147 | $wgFlaggedRevsPatrolLevel = 0; |
148 | 148 | |
149 | | -# Stability levels, defined below, that appear in protection form |
| 149 | +# Protection levels, defined below, that appear in protection form. |
| 150 | +# The stable version is the default for each level. A "none" level |
| 151 | +# will appear in the forms as well, to restore the default settings. |
150 | 152 | $wgFlaggedRevsProtectLevels = array(); |
151 | 153 | /* (example usage) |
152 | 154 | $wgFlaggedRevsProtectLevels = array( |
153 | | - 'semi-review' => array('select' => FLAGGED_VIS_LATEST, 'override' => true, 'autoreview' => ''), |
154 | | - 'intm-review' => array('select' => FLAGGED_VIS_LATEST, 'override' => true, 'autoreview' => 'review'), |
| 155 | + 'semi-review' => array('select' => FLAGGED_VIS_LATEST, 'autoreview' => ''), |
| 156 | + 'intm-review' => array('select' => FLAGGED_VIS_LATEST, 'autoreview' => 'review'), |
155 | 157 | ); |
156 | 158 | */ |
157 | 159 | |
158 | 160 | # Restriction levels for auto-review right at Stabilization page |
| 161 | +# No effect if $wgFlaggedRevsProtectLevels is used. |
159 | 162 | $wgFlaggedRevsRestrictionLevels = array( '', 'sysop' ); |
160 | 163 | |
161 | 164 | # Please set these as something different. Any text will do, though it probably |
Index: trunk/extensions/FlaggedRevs/FlaggedRevs.class.php |
— | — | @@ -80,15 +80,13 @@ |
81 | 81 | $wgFlaggedRevsProtectLevels = (array)$wgFlaggedRevsProtectLevels; |
82 | 82 | foreach ( $wgFlaggedRevsProtectLevels as $level => $config ) { |
83 | 83 | # Sanity check that the config is complete |
84 | | - if ( !isset( $config['select'] ) || !isset( $config['override'] ) |
85 | | - || !isset( $config['autoreview'] ) |
86 | | - ) { |
| 84 | + if ( !isset( $config['select'] ) || !isset( $config['autoreview'] ) ) { |
87 | 85 | throw new MWException( 'FlaggedRevs given incomplete $wgFlaggedRevsProtectLevels value!' ); |
88 | 86 | # Disallow reserved level names |
89 | 87 | } else if ( $level == 'invalid' || $level == 'none' ) { |
90 | 88 | throw new MWException( 'FlaggedRevs given reserved $wgFlaggedRevsProtectLevels key!' ); |
91 | 89 | } |
92 | | - $config['override'] = intval( $config['override'] ); // Type cleanup |
| 90 | + $config['override'] = 1; // stable is default |
93 | 91 | self::$protectionLevels[$level] = $config; |
94 | 92 | } |
95 | 93 | global $wgFlaggedRevsRestrictionLevels; |