mirror of
https://github.com/bumi/lntip
synced 2025-06-16 09:45:35 +00:00
Merge pull request #60 from reneaaron/fix/isenabled
fix: implement webln spec
This commit is contained in:
commit
70028e4264
@ -120,15 +120,11 @@ class LnMe {
|
|||||||
}
|
}
|
||||||
|
|
||||||
payWithWebln() {
|
payWithWebln() {
|
||||||
if (!webln.isEnabled) {
|
|
||||||
webln.enable().then((weblnResponse) => {
|
webln.enable().then((weblnResponse) => {
|
||||||
return webln.sendPayment(this.invoice.payment_request);
|
return webln.sendPayment(this.invoice.payment_request);
|
||||||
}).catch((e) => {
|
}).catch((e) => {
|
||||||
return this.showPaymentRequest();
|
return this.showPaymentRequest();
|
||||||
})
|
})
|
||||||
} else {
|
|
||||||
return webln.sendPayment(this.invoice.payment_request);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
populatePaymentRequest() {
|
populatePaymentRequest() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user