From: Huji Date: Thu, 15 May 2008 15:17:23 +0000 (+0000) Subject: r34676 also affected {{CURRENTVERSION}} : It used to return plain text, like the... X-Git-Tag: 1.31.0-rc.0~47615 X-Git-Url: http://git.cyclocoop.org/%28?a=commitdiff_plain;h=7412476b107e086a2accd0ded383267f97e86e41;p=lhc%2Fweb%2Fwiklou.git r34676 also affected {{CURRENTVERSION}} : It used to return plain text, like the other magic words, but with r34676 it returned an external link, so [[Special:Version|{{CURRENTVERSION}}]] wouldn't work. With this revision, CURRENTVERSION will work like previously. --- diff --git a/includes/SpecialVersion.php b/includes/SpecialVersion.php index 08fe0988dc..715af17478 100644 --- a/includes/SpecialVersion.php +++ b/includes/SpecialVersion.php @@ -86,7 +86,7 @@ class SpecialVersion { \n [http://www.mediawiki.org/ MediaWiki] - " . self::getVersion() . " + " . self::getVersionLinked() . " \n [http://www.php.net/ PHP] @@ -101,6 +101,16 @@ class SpecialVersion { /** Return a string of the MediaWiki version with SVN revision if available */ public static function getVersion() { + global $wgVersion, $IP; + wfProfileIn( __METHOD__ ); + $svn = self::getSvnRevision( $IP ); + $version = $svn ? "$wgVersion (r$svn)" : $wgVersion; + wfProfileOut( __METHOD__ ); + return $version; + } + + /** Return a string of the MediaWiki version with a link to SVN revision if available */ + public static function getVersionLinked() { global $wgVersion, $IP; wfProfileIn( __METHOD__ ); $svn = self::getSvnRevision( $IP );