r84201 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r84200‎ | r84201 | r84202 >
Date:20:37, 17 March 2011
Author:hashar
Status:ok
Tags:
Comment:
parseInt with base 10, update comment (number -> num)

follow up r83619
Modified paths:
  • /trunk/phase3/resources/mediawiki.language/mediawiki.language.js (modified) (history)

Diff [purge]

Index: trunk/phase3/resources/mediawiki.language/mediawiki.language.js
@@ -65,7 +65,7 @@
6666 /**
6767 * Converts a number using digitTransformTable.
6868 *
69 - * @param {number} number Value to be converted
 69+ * @param {num} number Value to be converted
7070 * @param {boolean} integer Convert the return value to an integer
7171 */
7272 'convertNumber': function( num, integer ) {
@@ -94,7 +94,7 @@
9595 convertedNumber += numberString[i];
9696 }
9797 }
98 - return integer ? parseInt( convertedNumber ) : convertedNumber;
 98+ return integer ? parseInt( convertedNumber, 10 ) : convertedNumber;
9999 },
100100 // Digit Transform Table, populated by language classes where applicable
101101 'digitTransformTable': null

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r83619fixed some parseInts to have a base, renamed a var from number -> num since n...neilk00:14, 10 March 2011

Status & tagging log