From b9702dfa3f60609cc227535033da268059932ba6 Mon Sep 17 00:00:00 2001 From: Gustavo Maximiliano Cortez Date: Thu, 4 Sep 2014 11:42:21 -0300 Subject: [PATCH] Fixes parseFloat for compatibility with all browsers --- js/controllers/send.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/controllers/send.js b/js/controllers/send.js index 3dc673183..a3112a093 100644 --- a/js/controllers/send.js +++ b/js/controllers/send.js @@ -34,7 +34,7 @@ angular.module('copayApp.controllers').controller('SendController', set: function (newValue) { this._alternative = newValue; if (typeof(newValue) === 'number' && $scope.isRateAvailable) { - this._amount = Number.parseFloat( + this._amount = parseFloat( (rateService.fromFiat(newValue, config.alternativeIsoCode) * satToUnit ).toFixed(config.unitDecimals), 10); } else { @@ -52,7 +52,7 @@ angular.module('copayApp.controllers').controller('SendController', set: function (newValue) { this._amount = newValue; if (typeof(newValue) === 'number' && $scope.isRateAvailable) { - this._alternative = Number.parseFloat( + this._alternative = parseFloat( (rateService.toFiat(newValue * config.unitToSatoshi, config.alternativeIsoCode) ).toFixed(2), 10); } else {