API Cleanup: renamed '_badcontinue'->'badcontinue', one die()
[lhc/web/wiklou.git] / includes / api / ApiQueryAllPages.php
index a5abae7..b180572 100644 (file)
@@ -69,10 +69,7 @@ class ApiQueryAllPages extends ApiQueryGeneratorBase {
 
                if ( !is_null( $params['continue'] ) ) {
                        $cont = explode( '|', $params['continue'] );
-                       if ( count( $cont ) != 1 ) {
-                               $this->dieUsage( "Invalid continue param. You should pass the " .
-                                       "original value returned by the previous query", "_badcontinue" );
-                       }
+                       $this->dieContinueUsageIf( count( $cont ) != 1 );
                        $op = $params['dir'] == 'descending' ? '<' : '>';
                        $cont_from = $db->addQuotes( $cont[0] );
                        $this->addWhere( "page_title $op= $cont_from" );
@@ -336,7 +333,6 @@ class ApiQueryAllPages extends ApiQueryGeneratorBase {
                return array_merge( parent::getPossibleErrors(), array(
                        array( 'code' => 'params', 'info' => 'Use "gapfilterredir=nonredirects" option instead of "redirects" when using allpages as a generator' ),
                        array( 'code' => 'params', 'info' => 'prlevel may not be used without prtype' ),
-                       array( 'code' => '_badcontinue', 'info' => 'Invalid continue param. You should pass the original value returned by the previous query' ),
                ) );
        }