Fix rounding error
This commit is contained in:
parent
eec0c32d8b
commit
c3a443538c
2 changed files with 2 additions and 2 deletions
|
|
@ -139,7 +139,7 @@ angular.module('copayApp.controllers').controller('buyAmazonController', functio
|
|||
|
||||
var outputs = [];
|
||||
var toAddress = invoice.bitcoinAddress;
|
||||
var amountSat = parseInt(invoice.btcDue * 100000000); // BTC to Satoshi
|
||||
var amountSat = parseInt((invoice.btcDue * 100000000).toFixed(0)); // BTC to Satoshi
|
||||
|
||||
outputs.push({
|
||||
'toAddress': toAddress,
|
||||
|
|
|
|||
|
|
@ -117,7 +117,7 @@ angular.module('copayApp.controllers').controller('topUpController', function($s
|
|||
|
||||
var outputs = [];
|
||||
var toAddress = invoice.bitcoinAddress;
|
||||
var amountSat = parseInt(invoice.btcDue * 100000000); // BTC to Satoshi
|
||||
var amountSat = parseInt((invoice.btcDue * 100000000).toFixed(0)); // BTC to Satoshi
|
||||
|
||||
outputs.push({
|
||||
'toAddress': toAddress,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue