* (bug 2087) Fixed a bug that made it impossible to pass "0" to any special
authorÆvar Arnfjörð Bjarmason <avar@users.mediawiki.org>
Fri, 6 May 2005 05:48:57 +0000 (05:48 +0000)
committerÆvar Arnfjörð Bjarmason <avar@users.mediawiki.org>
Fri, 6 May 2005 05:48:57 +0000 (05:48 +0000)
  page with the Special:Page/0 syntax.

includes/SpecialAllpages.php
includes/SpecialPage.php

index 87a24d6..73d7ce1 100644 (file)
@@ -35,9 +35,9 @@ function wfSpecialAllpages( $par=NULL ) {
                        );
        }
        
-       if ( $par ) {
+       if ( isset($par) ) {
                indexShowChunk( $namespace, $par, $invert );
-       } elseif ( $from ) {
+       } elseif ( isset($from) ) {
                indexShowChunk( $namespace, $from, $invert );
        } else {
                indexShowToplevel ( $namespace, $invert );
index 7c2cb87..2c7faff 100644 (file)
@@ -202,7 +202,7 @@ class SpecialPage
 
                $bits = split( "/", $title->getDBkey(), 2 );
                $name = $bits[0];
-               if( empty( $bits[1] ) ) {
+               if( !isset( $bits[1] ) ) { // bug 2087
                        $par = NULL;
                } else {
                        $par = $bits[1];