From d6cf07fac52fc9c4c1ccdd1d6b2f730993031c59 Mon Sep 17 00:00:00 2001 From: karun Date: Tue, 18 Dec 2012 09:48:53 +1100 Subject: [PATCH] (bug 43184) bogus script path in Special:Version Corrected display of script path change so that when the script path is empty, we default to showing / as the path. Change-Id: I8bb6ff820fa3f8d7c3cdd608f531c0f3c36389ca --- includes/specials/SpecialVersion.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/includes/specials/SpecialVersion.php b/includes/specials/SpecialVersion.php index 0ff5fc913d..01a12c0f84 100644 --- a/includes/specials/SpecialVersion.php +++ b/includes/specials/SpecialVersion.php @@ -775,15 +775,17 @@ class SpecialVersion extends SpecialPage { return $repo->getHeadSHA1(); } + /** * Get the list of entry points and their URLs * @return string Wikitext */ public function getEntryPointInfo() { global $wgArticlePath, $wgScriptPath; + $scriptPath = $wgScriptPath ? $wgScriptPath : "/"; $entryPoints = array( 'version-entrypoints-articlepath' => $wgArticlePath, - 'version-entrypoints-scriptpath' => $wgScriptPath, + 'version-entrypoints-scriptpath' => $scriptPath, 'version-entrypoints-index-php' => wfScript( 'index' ), 'version-entrypoints-api-php' => wfScript( 'api' ), 'version-entrypoints-load-php' => wfScript( 'load' ), -- 2.20.1