1
0

auth_protect: pass authMessage in the auth_protect decorator,

instead of relying on side-effects

This is probably safer, and also more self-contained.
This commit is contained in:
ThomasV
2023-04-17 18:17:29 +02:00
parent 73dd6827e0
commit a03f4769ca
7 changed files with 34 additions and 51 deletions

View File

@@ -584,7 +584,7 @@ class QEWallet(AuthMixin, QObject, QtEventListener):
def ln_auth_rejected(self):
self.paymentAuthRejected.emit()
@auth_protect(reject='ln_auth_rejected')
@auth_protect(message=_('Pay lightning invoice?'), reject='ln_auth_rejected')
def pay_lightning_invoice(self, invoice: 'QEInvoice'):
amount_msat = invoice.get_amount_msat()