User "Dantman" posted a comment on MediaWiki.r99570.

Full URL: http://www.mediawiki.org/wiki/Special:Code/MediaWiki/99570#c24166
Commit summary:

Contest: Fix version check. Has to check for >1.18 rather than >=1.19 because 
version_compare() behaves strangely for versions like 1.19alpha and 1.19wmf1

Comment:

It's not exactly strange, 1.19alpha is earlier than 1.19 release so php treats 
it that way. Hence a lot of comparisons actually use <code>version_compare( 
$wgVersion, '1.19alpha', '>=' );</code> though I admit it's a little strange 
with the wmf1.

In any case, in this situation you should be feature testing '''not''' version 
testing.
<source lang=php>method_exists( 'TablePager', 'getLang' );</source>

_______________________________________________
MediaWiki-CodeReview mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-codereview

Reply via email to