$errors = array();
// wfFindFile( $nt ) / wfLocalFile( $nt ) is not allowed until below
-
+
$file = wfLocalFile( $this );
if ( $file->exists() ) {
if ( $nt->getText() != wfStripIllegalFilenameChars( $nt->getText() ) ) {
$errors[] = array( 'imagetypemismatch' );
}
}
-
+
if ( $nt->getNamespace() != NS_FILE ) {
$errors[] = array( 'imagenocrossnamespace' );
- // From here we want to do checks on a file object, so if we can't
+ // From here we want to do checks on a file object, so if we can't
// create one, we must return.
return $errors;
}
-
+
// wfFindFile( $nt ) / wfLocalFile( $nt ) is allowed below here
$destFile = wfLocalFile( $nt );
array( 'rc_timestamp' => $rcts, 'rc_namespace' => $newns, 'rc_title' => $newdbk, 'rc_new' => 1 ),
__METHOD__
);
- __METHOD__ );
}
# Save a null revision in the page's history notifying of the move