diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2012-06-13 23:40:19 +0200 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2012-06-13 23:40:19 +0200 |
commit | 588cc40aeec0165400421ef9612e81b6d2c7b936 (patch) | |
tree | 85f1e86ba187fbc81ef42393433f1fa5aa6defb3 /includes/specials | |
parent | 67674d7a741c7c1de947f30ceb1ab3b35283308e (diff) |
Update to MediaWiki 1.19.1
Diffstat (limited to 'includes/specials')
-rw-r--r-- | includes/specials/SpecialMovepage.php | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/includes/specials/SpecialMovepage.php b/includes/specials/SpecialMovepage.php index d7ebd310..5536fbc9 100644 --- a/includes/specials/SpecialMovepage.php +++ b/includes/specials/SpecialMovepage.php @@ -55,6 +55,13 @@ class MovePageForm extends UnlistedSpecialPage { $oldTitleText = $request->getVal( 'wpOldTitle', $target ); $this->oldTitle = Title::newFromText( $oldTitleText ); + if( is_null( $this->oldTitle ) ) { + throw new ErrorPageError( 'notargettitle', 'notargettext' ); + } + if( !$this->oldTitle->exists() ) { + throw new ErrorPageError( 'nopagetitle', 'nopagetext' ); + } + $newTitleTextMain = $request->getText( 'wpNewTitleMain' ); $newTitleTextNs = $request->getInt( 'wpNewTitleNs', $this->oldTitle->getNamespace() ); // Backwards compatibility for forms submitting here from other sources @@ -64,12 +71,6 @@ class MovePageForm extends UnlistedSpecialPage { ? Title::newFromText( $newTitleText_bc ) : Title::makeTitleSafe( $newTitleTextNs, $newTitleTextMain ); - if( is_null( $this->oldTitle ) ) { - throw new ErrorPageError( 'notargettitle', 'notargettext' ); - } - if( !$this->oldTitle->exists() ) { - throw new ErrorPageError( 'nopagetitle', 'nopagetext' ); - } $user = $this->getUser(); |