aboutsummaryrefslogtreecommitdiffstats
path: root/routes/bitcoin
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2021-06-05 01:14:56 -0400
committerAdam Soltys <[email protected]>2021-06-05 01:14:56 -0400
commit421accbfbc0a1add93f7704e657ae93f2d836b82 (patch)
tree16807bc65a82ca80c5878d81c1c8dd945e8fccc9 /routes/bitcoin
parent3bdd16bb7a757f33587c9ef5834fa47c1ee00210 (diff)
downloadcoinos-server-421accbfbc0a1add93f7704e657ae93f2d836b82.tar.gz
coinos-server-421accbfbc0a1add93f7704e657ae93f2d836b82.zip
bump address indices
Diffstat (limited to 'routes/bitcoin')
-rw-r--r--routes/bitcoin/send.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/routes/bitcoin/send.js b/routes/bitcoin/send.js
index f1814b08..cab79e06 100644
--- a/routes/bitcoin/send.js
+++ b/routes/bitcoin/send.js
@@ -7,6 +7,7 @@ module.exports = ah(async (req, res) => {
let { hex } = tx;
let fee = toSats(tx.fee);
+ if (fee < 0) throw new Error("fee cannot be negative");
const isChange = async address =>
(await bc.getAddressInfo(address)).ismine &&