double-check with isLocal() to be safe
authorAaron Schulz <aaron@users.mediawiki.org>
Fri, 15 Aug 2008 18:28:54 +0000 (18:28 +0000)
committerAaron Schulz <aaron@users.mediawiki.org>
Fri, 15 Aug 2008 18:28:54 +0000 (18:28 +0000)
includes/specials/SpecialAllpages.php

index da35b7c..d190eb6 100644 (file)
@@ -114,8 +114,8 @@ function showToplevel( $namespace = NS_MAIN, $from = '', $to = '', $including =
        
        $from = Title::makeTitleSafe( $namespace, $from );
        $to = Title::makeTitleSafe( $namespace, $to );
-       $from = $from ? $from->getDBKey() : null;
-       $to = $to ? $to->getDBKey() : null;
+       $from = ( $from && $from->isLocal() ) ? $from->getDBKey() : null;
+       $to = ( $to && $to->isLocal() ) ? $to->getDBKey() : null;
        
        if( isset($from) )
                $where[] = 'page_title >= '.$dbr->addQuotes( $from );