fix rounding errs at valueOut

This commit is contained in:
Matias Alejo Garcia 2014-02-10 15:49:33 -03:00
parent 280f815f97
commit 9910fa4d40
1 changed files with 3 additions and 3 deletions

View File

@ -32,11 +32,11 @@ function spec(b) {
});
// Outputs
var valueOut = 0;
var valueOutSat = 0;
info.vout.forEach( function(o) {
valueOut += o.value;
valueOutSat += o.value * util.COIN;
});
info.valueOut = valueOut;
info.valueOut = parseInt(valueOutSat) / util.COIN;
info.size = b.length;
return info;