* Enforce $wgSVGMaxSize when rendering, even for SVGs with a very large source
size. This is necessary to limit server memory usage.
* Cleanup and error checking on Special:Listredirects
-
+* Clear up some instances of old OutputPage::sysopRequired() function usage
=== Caveats ===
global $wgOut, $wgRequest, $wgOnlySysopsCanPatrol, $wgUseRCPatrol, $wgUser;
$wgOut->setRobotpolicy( 'noindex,follow' );
- if ( !$wgUseRCPatrol )
- {
- $wgOut->errorpage( 'rcpatroldisabled', 'rcpatroldisabledtext' );
+ # Check RC patrol config. option
+ if( !$wgUseRCPatrol ) {
+ $wgOut->errorPage( 'rcpatroldisabled', 'rcpatroldisabledtext' );
return;
}
- if ( $wgUser->isAnon() )
- {
+
+ # Check permissions
+ if( $wgUser->isLoggedIn() ) {
+ if( !$wgUser->isAllowed( 'patrol' ) ) {
+ $wgOut->permissionRequired( 'patrol' );
+ return;
+ }
+ } else {
$wgOut->loginToUse();
return;
}
- if ( $wgOnlySysopsCanPatrol && !$wgUser->isAllowed('patrol') )
- {
- $wgOut->sysopRequired();
- return;
- }
+
$rcid = $wgRequest->getVal( 'rcid' );
if ( !is_null ( $rcid ) )
{
return;
}
} else {
- $wgOut->sysopRequired();
+ $wgOut->permissionRequired( 'delete' );
return;
}
return;
}
} else {
- $wgOut->sysopRequired();
+ $wgOut->permissionRequired( 'rollback' );
return;
}