Removed check for empty( $action ), seems to be old register_globals code, but since...
authorAlexandre Emsenhuber <ialex@users.mediawiki.org>
Wed, 4 Feb 2009 19:43:30 +0000 (19:43 +0000)
committerAlexandre Emsenhuber <ialex@users.mediawiki.org>
Wed, 4 Feb 2009 19:43:30 +0000 (19:43 +0000)
$action = $wgRequest->getVal( 'action', 'view' );
it can't match empty() in "normal" conditions

includes/OutputPage.php

index b1a0275..acf7986 100644 (file)
@@ -309,20 +309,20 @@ class OutputPage {
                }
        }
 
-       public function setHTMLTitle( $name ) {$this->mHTMLtitle = $name; }
+       public function setHTMLTitle( $name ) { $this->mHTMLtitle = $name; }
        public function setPageTitle( $name ) {
-               global $action, $wgContLang;
-               $name = $wgContLang->convert($name, true);
+               global $wgContLang;
+               $name = $wgContLang->convert( $name, true );
                $this->mPagetitle = $name;
-               if(!empty($action)) {
-                       $taction =  $this->getPageTitleActionText();
-                       if( !empty( $taction ) ) {
-                               $name .= ' - '.$taction;
-                       }
+
+               $taction =  $this->getPageTitleActionText();
+               if( !empty( $taction ) ) {
+                       $name .= ' - '.$taction;
                }
 
                $this->setHTMLTitle( wfMsg( 'pagetitle', $name ) );
        }
+
        public function getHTMLTitle() { return $this->mHTMLtitle; }
        public function getPageTitle() { return $this->mPagetitle; }
        public function setSubtitle( $str ) { $this->mSubtitle = /*$this->parse(*/$str/*)*/; } // @bug 2514