Merge "Fixed many small spelling mistakes and php docs, var decl."
[lhc/web/wiklou.git] / includes / api / ApiQueryAllPages.php
index 1667a85..d718b96 100644 (file)
@@ -117,7 +117,7 @@ class ApiQueryAllPages extends ApiQueryGeneratorBase {
                if ( count( $params['prtype'] ) || $params['prexpiry'] != 'all' ) {
                        $this->addTables( 'page_restrictions' );
                        $this->addWhere( 'page_id=pr_page' );
-                       $this->addWhere( 'pr_expiry>' . $db->addQuotes( $db->timestamp() ) );
+                       $this->addWhere( "pr_expiry > {$db->addQuotes( $db->timestamp() )} OR pr_expiry IS NULL" );
 
                        if ( count( $params['prtype'] ) ) {
                                $this->addWhereFld( 'pr_type', $params['prtype'] );
@@ -347,7 +347,7 @@ class ApiQueryAllPages extends ApiQueryGeneratorBase {
                                'Show info about 4 pages starting at the letter "T"',
                        ),
                        'api.php?action=query&generator=allpages&gaplimit=2&gapfilterredir=nonredirects&gapfrom=Re&prop=revisions&rvprop=content' => array(
-                               'Show content of first 2 non-redirect pages begining at "Re"',
+                               'Show content of first 2 non-redirect pages beginning at "Re"',
                        )
                );
        }