electrum

Electrum Bitcoin wallet
git clone https://git.parazyd.org/electrum
Log | Files | Refs | Submodules

commit 986de70529d2fd3733575625eacf8f34ea9ae036
parent 895f9daded603332c2ebeda686b6515cdcb25591
Author: ThomasV <thomasv@electrum.org>
Date:   Sun, 24 Jan 2021 11:40:02 +0100

Qt: fix invoices refresh (follow-up 94708f63e4f237f5f4c143137de797f9c0ccc08e)

Diffstat:
Melectrum/gui/qt/main_window.py | 18++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)

diff --git a/electrum/gui/qt/main_window.py b/electrum/gui/qt/main_window.py @@ -1520,21 +1520,23 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, Logger): req = self.wallet.receive_requests.get(key) if req is None: return - self.request_list.update_item(key, req) - self.request_list.update() - if status == PR_PAID: self.notify(_('Payment received') + '\n' + key) - self.need_update.set() + self.request_list.update() + else: + self.request_list.update_item(key, req) def on_invoice_status(self, wallet, key): if wallet != self.wallet: return - req = self.wallet.get_invoice(key) - if req is None: + invoice = self.wallet.get_invoice(key) + if invoice is None: return - self.invoice_list.update_item(key, req) - self.invoice_list.update() + status = self.wallet.get_invoice_status(invoice) + if status == PR_PAID: + self.invoice_list.update() + else: + self.invoice_list.update_item(key, invoice) def on_payment_succeeded(self, wallet, key): description = self.wallet.get_label(key)