Revert to version without optional digits, for speed reasons.

Since we don't actually use the other version anywhere.
This commit is contained in:
Jürg Lehni 2012-11-06 07:17:14 -08:00
parent aa35226916
commit 1fad063a30

View file

@ -199,11 +199,9 @@ this.Base = Base.inject(/** @lends Base# */{
* up to the amount of fractional digits.
*
* @param {Number} num the number to be converted to a string
* @param {Number} [digits=5] the maximum maount of fraction digits
*/
formatNumber: function(num, digits) {
var factor = Math.pow(10, digits | 5);
return (Math.round(num * factor) / factor).toString();
formatNumber: function(num) {
return (Math.round(num * 100000) / 100000).toString();
}
}
});