*/
define( 'MW_NO_OUTPUT_COMPRESSION', 1 );
if ( isset( $_SERVER['MW_COMPILED'] ) ) {
- require ( 'phase3/includes/WebStart.php' );
+ require( 'phase3/includes/WebStart.php' );
} else {
- require ( dirname( __FILE__ ) . '/includes/WebStart.php' );
+ require( dirname( __FILE__ ) . '/includes/WebStart.php' );
}
// Don't use fancy mime detection, just check the file extension for jpg/gif/png
// Check permissions if there are read restrictions
if ( !in_array( 'read', User::getGroupPermissions( array( '*' ) ), true ) ) {
- if ( !$img->getTitle()->userCanRead() ) {
+ if ( !$img->getTitle()->userCan( 'read' ) ) {
wfThumbError( 403, 'Access denied. You do not have permission to access ' .
'the source file.' );
wfProfileOut( __METHOD__ );