From: Raimond Spekking Date: Tue, 30 Dec 2008 16:12:49 +0000 (+0000) Subject: Show subversion too even if a "normal" version number is available X-Git-Tag: 1.31.0-rc.0~43697 X-Git-Url: http://git.cyclocoop.org///%22%40url%40//%22?a=commitdiff_plain;h=d153ebb35d8b7d08ef9c5089b86442c84f550dca;p=lhc%2Fweb%2Fwiklou.git Show subversion too even if a "normal" version number is available --- diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 7d6d2f127d..32cd5ae96e 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -254,6 +254,7 @@ The following extensions are migrated into MediaWiki 1.14: * (bug 16754) Making arbitrary rows of sortable tables sticky: |- class="unsortable" * (bug 16617) Add "talk" link to list of templates in edit mode +* Show subversion too even if a "normal" version number is available === Bug fixes in 1.14 === diff --git a/includes/specials/SpecialVersion.php b/includes/specials/SpecialVersion.php index bd7ccab580..29f527f2d6 100644 --- a/includes/specials/SpecialVersion.php +++ b/includes/specials/SpecialVersion.php @@ -157,15 +157,21 @@ class SpecialVersion extends SpecialPage { usort( $wgExtensionCredits[$type], array( $this, 'compare' ) ); foreach ( $wgExtensionCredits[$type] as $extension ) { + $version = null; + $subVersion = ''; if ( isset( $extension['version'] ) ) { $version = $extension['version']; - } elseif ( isset( $extension['svn-revision'] ) && + } + if ( isset( $extension['svn-revision'] ) && preg_match( '/\$(?:Rev|LastChangedRevision|Revision): *(\d+)/', - $extension['svn-revision'], $m ) ) - { - $version = 'r' . $m[1]; - } else { - $version = null; + $extension['svn-revision'], $m ) ) { + $subVersion = 'r' . $m[1]; + } + + if( $version && $subVersion ) { + $version = $version . ' [' . $subVersion . ']'; + } elseif ( !$version && $subVersion ) { + $version = $subVersion; } $out .= $this->formatCredits(