From 2fe8beac2878f083eea1597e0bd97e1b376a0b24 Mon Sep 17 00:00:00 2001 From: Paramjit Singh Sahota Date: Thu, 8 May 2014 18:51:17 +0530 Subject: [PATCH] Missed while merging. --- addons/website_sale/controllers/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/website_sale/controllers/main.py b/addons/website_sale/controllers/main.py index 082b3c7dfd7..efa0256eb1b 100644 --- a/addons/website_sale/controllers/main.py +++ b/addons/website_sale/controllers/main.py @@ -260,7 +260,7 @@ class website_sale(http.Controller): # if transaction pending / done: redirect to confirmation tx = context.get('website_sale_transaction') - if tx and tx.state != 'shopping_cart': + if tx.state != 'shopping_cart': return request.redirect('/shop/payment/confirmation/%s' % order.id) def checkout_values(self, data=None): @@ -537,7 +537,7 @@ class website_sale(http.Controller): 'sale_order_id': order.id, }, context=context) request.session['sale_transaction_id'] = tx_id - elif tx and tx.state == 'shopping_cart': # button cliked but no more info -> rewrite on tx or create a new one ? + elif tx.state == 'shopping_cart': # button cliked but no more info -> rewrite on tx or create a new one ? tx.write({ 'acquirer_id': acquirer_id, })