electrum

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

commit 6631ab9406efabc3dd203ac587672181abec0fc0
parent 503fd99cdb1256341ad6f2c1f504b2d6851035bd
Author: ThomasV <thomasv@gitorious>
Date:   Thu, 12 Jun 2014 15:47:48 +0200

verify if pr has expired

Diffstat:
Mgui/qt/main_window.py | 7+++++--
Mlib/paymentrequest.py | 6+++---
2 files changed, 8 insertions(+), 5 deletions(-)

diff --git a/gui/qt/main_window.py b/gui/qt/main_window.py @@ -1270,10 +1270,13 @@ class ElectrumWindow(QMainWindow): pr = PaymentRequest(self.config) pr.read_file(key) pr.domain = domain - pr.verify() self.gui_object.payment_request = pr self.prepare_for_payment_request() - self.payment_request_ok() + if pr.verify(): + self.payment_request_ok() + else: + self.payment_request_error() + def create_invoice_menu(self, position): item = self.invoices_list.itemAt(position) diff --git a/lib/paymentrequest.py b/lib/paymentrequest.py @@ -259,9 +259,9 @@ class PaymentRequest: self.payment_url = self.details.payment_url - #if self.has_expired(): - # self.error = "ERROR: Payment Request has Expired." - # return False + if self.has_expired(): + self.error = "ERROR: Payment Request has Expired." + return False return True