From: Kunal Mehta Date: Sat, 11 Oct 2014 01:39:24 +0000 (-0700) Subject: MovePage: Properly return errors X-Git-Tag: 1.31.0-rc.0~13633^2 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/banques/%7B%7B%20url_for%28%27admin_users%27%29%20%7D%7D?a=commitdiff_plain;h=e995e2ae4bb5299fa08f1dcc9f119db49226070f;p=lhc%2Fweb%2Fwiklou.git MovePage: Properly return errors Probably a copy-paste mistake when converting this function to use Status instead of error arrays. Change-Id: I796fc66ee637dd7d914a4182fe56992e59b90aba --- diff --git a/includes/MovePage.php b/includes/MovePage.php index 5c9490bca6..79095e9ae7 100644 --- a/includes/MovePage.php +++ b/includes/MovePage.php @@ -69,14 +69,14 @@ class MovePage { $oldid = $this->oldTitle->getArticleID(); if ( strlen( $this->newTitle->getDBkey() ) < 1 ) { - $errors[] = array( 'articleexists' ); + $status->fatal( 'articleexists' ); } if ( ( $this->oldTitle->getDBkey() == '' ) || ( !$oldid ) || ( $this->newTitle->getDBkey() == '' ) ) { - $errors[] = array( 'badarticleerror' ); + $status->fatal( 'badarticleerror' ); } // Content model checks