diff options
| author | Toufik Benjaa <tbe@odoo.com> | 2018-05-24 19:24:26 +0200 |
|---|---|---|
| committer | Toufik Benjaa <tbe@odoo.com> | 2018-05-24 19:24:26 +0200 |
| commit | b2aab354c4a6bcd37cded7c2d0129d9e1cc5d87d (patch) | |
| tree | 4b1d7bdb60dfff417a884b9607277761a2c47a6b | |
| parent | 56e3100a0b1f3232272d00638548f62f21a58d3a (diff) | |
[FIX] payment: Remove lang when creating payment transaction
- Having a lang set when trying to create a payment transaction can cause issues due to uninstalled langs on the database.
| -rw-r--r-- | addons/payment/controllers/portal.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/payment/controllers/portal.py b/addons/payment/controllers/portal.py index 6f13400356b..ded83ea59d1 100644 --- a/addons/payment/controllers/portal.py +++ b/addons/payment/controllers/portal.py @@ -92,7 +92,7 @@ class WebsitePayment(http.Controller): 'type': 'form_save' if acquirer.save_token != 'none' and partner_id else 'form', } - tx = request.env['payment.transaction'].sudo().create(values) + tx = request.env['payment.transaction'].sudo().with_context(lang=None).create(values) request.session['website_payment_tx_id'] = tx.id render_values = { @@ -122,7 +122,7 @@ class WebsitePayment(http.Controller): 'type': 'form_save' if token.acquirer_id.save_token != 'none' and partner_id else 'form', } - tx = request.env['payment.transaction'].sudo().create(values) + tx = request.env['payment.transaction'].sudo().with_context(lang=None).create(values) request.session['website_payment_tx_id'] = tx.id try: |
