aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2022-09-09 20:28:34 -0400
committerAdam Soltys <[email protected]>2022-09-09 20:28:34 -0400
commitfdb1494a717583a2048861b7c4b1cb6b283d0c0c (patch)
treebe766189818cbcc70407bad80f97c37e5537db84 /lib
parentb83e7189e66c4d4f04a029268e87af185bf7aee7 (diff)
downloadcoinos-server-fdb1494a717583a2048861b7c4b1cb6b283d0c0c.tar.gz
coinos-server-fdb1494a717583a2048861b7c4b1cb6b283d0c0c.zip
adjust ln fee settings
Diffstat (limited to 'lib')
-rw-r--r--lib/send.js8
1 files changed, 3 insertions, 5 deletions
diff --git a/lib/send.js b/lib/send.js
index 26709b61..77d954f6 100644
--- a/lib/send.js
+++ b/lib/send.js
@@ -9,7 +9,7 @@ import {
conversionFeeReceiver
} from "../routes/lightning/conversionFee";
import lnd from "$lib/lnd";
-import { pay } from "lightning";
+import { payViaPaymentRequest } from "lightning";
import { l, warn, err } from "$lib/logging";
export default async (amount, memo, hash, user) => {
@@ -89,12 +89,10 @@ export default async (amount, memo, hash, user) => {
let tokens;
if (!payreq.satoshis) tokens = amount;
- let m = await pay({
+ let m = await payViaPaymentRequest({
lnd,
- tokens,
request: hash,
- max_paths: 10,
- max_fee: { fixed: Math.min(10000, account.balance) }
+ max_fee: Math.min(10000, account.balance)
});
if (!m) throw new Error(`lightning payment failed ${amount} ${hash}`);