Revert Domas's last checkin, it broke tabs on redirects. Please test before checkin!
authorBrion Vibber <brion@users.mediawiki.org>
Sat, 14 Jan 2006 04:35:43 +0000 (04:35 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Sat, 14 Jan 2006 04:35:43 +0000 (04:35 +0000)
includes/Article.php

index 82891fc..6a1c0e3 100644 (file)
@@ -91,8 +91,11 @@ class Article {
                                        } else {
                                                return $rt->getFullURL();
                                        }
-                               } 
-                               return $rt;
+                               } elseif( $rt->exists() ) {
+                                       // Internal redirects can be handled relatively gracefully.
+                                       // We may have to change to another Article subclass, though.
+                                       return $rt;
+                               }
                        }
                }
                
@@ -424,7 +427,6 @@ class Article {
         * @access private
         */
        function loadPageData( $data ) {
-               $this->mTitle->mArticleID = $data->page_id;
                $this->mTitle->loadRestrictions( $data->page_restrictions );
                $this->mTitle->mRestrictionsLoaded = true;