r75466 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r75465‎ | r75466 | r75467 >
Date:20:09, 26 October 2010
Author:hashar
Status:ok
Tags:
Comment:
Follow up r75446 : simpler bench function, correct parenthesis.
Modified paths:
  • /trunk/phase3/maintenance/benchmarks/bench_wfIsWindows.php (modified) (history)

Diff [purge]

Index: trunk/phase3/maintenance/benchmarks/bench_wfIsWindows.php
@@ -20,16 +20,12 @@
2121 }
2222
2323 static function is_win() {
24 - return substr( php_uname(), 0, 7 == 'Windows' );
 24+ return substr( php_uname(), 0, 7 ) == 'Windows' ;
2525 }
2626
2727 // bench function 1
2828 function wfIsWindows() {
29 - if( self::is_win() ) {
30 - return true;
31 - } else {
32 - return false;
33 - }
 29+ return self::is_win();
3430 }
3531
3632 // bench function 2

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r75446Follow up r75429 : benchmark for wfIsWindows();...hashar17:21, 26 October 2010

Status & tagging log