* (bug 24313) The preference to mark edits minor by default was removed,
because it encourages edits to be marked minor accidentally and it can be
easily replicated by custom user scripts for those who really want it.
+* Non-file pages can no longer be moved to the file namespace, nor vice versa.
=== Bug fixes in 1.17 ===
* (bug 17560) Half-broken deletion moved image files to deletion archive
// Image-specific checks
if ( $this->getNamespace() == NS_FILE ) {
+ if ( $nt->getNamespace() != NS_FILE ) {
+ $errors[] = array( 'imagenocrossnamespace' );
+ }
$file = wfLocalFile( $this );
if ( $file->exists() ) {
- if ( $nt->getNamespace() != NS_FILE ) {
- $errors[] = array( 'imagenocrossnamespace' );
- }
if ( $nt->getText() != wfStripIllegalFilenameChars( $nt->getText() ) ) {
$errors[] = array( 'imageinvalidfilename' );
}
if ( !$wgUser->isAllowed( 'reupload-shared' ) && !$destfile->exists() && wfFindFile( $nt ) ) {
$errors[] = array( 'file-exists-sharedrepo' );
}
+ }
+ if ( $nt->getNamespace() == NS_FILE && $this->getNamespace() != NS_FILE ) {
+ $errors[] = array( 'nonfile-cannot-move-to-file' );
}
if ( $auth ) {
'immobile-source-page' => 'This page is not movable.',
'immobile-target-page' => 'Cannot move to that destination title.',
'imagenocrossnamespace' => 'Cannot move file to non-file namespace',
+'nonfile-cannot-move-to-file' => 'Cannot move non-file to file namespace',
'imagetypemismatch' => 'The new file extension does not match its type',
'imageinvalidfilename' => 'The target file name is invalid',
'fix-double-redirects' => 'Update any redirects that point to the original title',
'immobile-target-page',
'immobile_namespace',
'imagenocrossnamespace',
+ 'nonfile-cannot-move-to-file',
'imagetypemismatch',
'imageinvalidfilename',
'fix-double-redirects',