aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2020-05-02 15:10:56 -0700
committerAdam Soltys <[email protected]>2020-05-02 15:10:56 -0700
commitc2f6dd746000d561750d1e32c05cc814e39a40ce (patch)
tree90de1814a1ac1c833950e15249ff6bac841283b8
parent209b3823746312a27c03cf5da3e4989ef389f5f5 (diff)
downloadcoinos-server-c2f6dd746000d561750d1e32c05cc814e39a40ce.tar.gz
coinos-server-c2f6dd746000d561750d1e32c05cc814e39a40ce.zip
check amt_paid not value field for lightning payments
-rw-r--r--routes/lightning/receive.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/routes/lightning/receive.js b/routes/lightning/receive.js
index 980d9e01..286541d2 100644
--- a/routes/lightning/receive.js
+++ b/routes/lightning/receive.js
@@ -12,7 +12,7 @@ const handlePayment = async msg => {
if (!invoice) return;
const { text: hash, currency, rate, tip, user_id } = invoice;
- const amount = parseInt(msg.value) - tip;
+ const amount = parseInt(msg.amt_paid_sat) - tip;
const account = await db.Account.findOne({
where: {