aboutsummaryrefslogtreecommitdiffstats
path: root/lib/ln.js
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2022-09-02 23:32:30 -0700
committerAdam Soltys <[email protected]>2022-09-02 23:32:30 -0700
commit981321e3722af3aba217aeddfba3843615085ec7 (patch)
treed46dab617a6e8f33980275db362aa000e0447939 /lib/ln.js
parent13352f9b30eed52d2e7d0970d3cbd76f401d6de0 (diff)
downloadcoinos-server-981321e3722af3aba217aeddfba3843615085ec7.tar.gz
coinos-server-981321e3722af3aba217aeddfba3843615085ec7.zip
es6 migration
Diffstat (limited to 'lib/ln.js')
-rw-r--r--lib/ln.js17
1 files changed, 1 insertions, 16 deletions
diff --git a/lib/ln.js b/lib/ln.js
index 91a704e9..b1f9962d 100644
--- a/lib/ln.js
+++ b/lib/ln.js
@@ -4,22 +4,7 @@ let ln;
if (config.lna.clightning) {
ln = (await import("clightning-client"))(config.lna.dir);
} else {
- let lnd = await import("../lib/lnd");
- ln = [
- "addInvoice",
- "channelBalance",
- "connectPeer",
- "decodePayReq",
- "getInfo",
- "listInvoices",
- "listPayments",
- "sendPaymentSync",
- "walletBalance"
- ].reduce(
- (a, b) =>
- (a[b] = args => new Promise(r => lnd[b](args, (e, v) => r(v)))) && a,
- {}
- );
+ ln = (await import("./lnd.js"));
}
export default ln;