From e839396d401a6267e4aebfea645718b945bdc3cd Mon Sep 17 00:00:00 2001 From: Thomas Steen Rasmussen Date: Tue, 20 Jun 2017 00:18:57 +0200 Subject: [PATCH] right, tempinvoice --- src/shop/views.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/shop/views.py b/src/shop/views.py index 19092ec4..081e1eac 100644 --- a/src/shop/views.py +++ b/src/shop/views.py @@ -540,7 +540,8 @@ class CoinifyRedirectView(LoginRequiredMixin, EnsureUserOwnsOrderMixin, EnsureUn coinifyinvoice = None for tempinvoice in order.coinify_api_invoices.all(): # we already have a coinifyinvoice for this order, check if it expired - if not coinifyinvoice.expired: + if not tempinvoice.expired: + # this invoice is not expired, we are good to go coinifyinvoice = tempinvoice break