$match = $magic->isMatchingExtension( $extension, $mime );
- if ( $match === NULL ) {
+ if ( $match === null ) {
wfDebug( __METHOD__ . ": no file extension known for mime type $mime, passing file\n" );
return true;
} elseif( $match === true ) {
elseif( substr( $chunk, 0, 2 ) == "\xff\xfe" )
$enc = "UTF-16LE";
else
- $enc = NULL;
+ $enc = null;
if( $enc )
$chunk = iconv( $enc, "ASCII//IGNORE", $chunk );
if ( !$wgAntivirus ) {
wfDebug( __METHOD__ . ": virus scanner disabled\n" );
- return NULL;
+ return null;
}
if ( !$wgAntivirusSetup[$wgAntivirus] ) {
if ( $wgAntivirusRequired ) {
return wfMsg( 'virus-scanfailed', array( $exitCode ) );
} else {
- return NULL;
+ return null;
}
} else if ( $mappedCode === AV_SCAN_ABORTED ) {
# scan failed because filetype is unknown (probably imune)
wfDebug( __METHOD__ . ": unsupported file type $file (code $exitCode).\n" );
- return NULL;
+ return null;
} else if ( $mappedCode === AV_NO_VIRUS ) {
# no virus found
wfDebug( __METHOD__ . ": file passed virus scan.\n" );