From: Marius Hoch Date: Sun, 19 May 2013 17:27:53 +0000 (+0200) Subject: Non existent user subpages should return 404 X-Git-Tag: 1.31.0-rc.0~19627^2 X-Git-Url: http://git.cyclocoop.org/data/%24oldEdit?a=commitdiff_plain;h=bbe0dfb8656d6ea6a5147275b77a0122220b4ec5;p=lhc%2Fweb%2Fwiklou.git Non existent user subpages should return 404 Bug: 46491 Change-Id: I900f1542b077b569ed64306ecf9f965ddabe59f8 --- diff --git a/includes/Article.php b/includes/Article.php index d23bebf073..a0d4438222 100644 --- a/includes/Article.php +++ b/includes/Article.php @@ -1092,6 +1092,7 @@ class Article implements Page { public function showMissingArticle() { global $wgSend404Code; $outputPage = $this->getContext()->getOutput(); + // Whether the page is a root user page of an existing user (but not a subpage) $validUserPage = false; # Show info in user (talk) namespace. Does the user exist? Is he blocked? @@ -1119,9 +1120,9 @@ class Article implements Page { ) ) ); - $validUserPage = true; + $validUserPage = !$this->getTitle()->isSubpage(); } else { - $validUserPage = true; + $validUserPage = !$this->getTitle()->isSubpage(); } }