diff options
| author | Martin Trigaux <mat@odoo.com> | 2020-06-15 15:16:16 +0200 |
|---|---|---|
| committer | Martin Trigaux <mat@odoo.com> | 2020-06-18 13:03:34 +0200 |
| commit | 80e97e98ce76067db1079af8feeef667cfadf837 (patch) | |
| tree | e261d34e3f8458bd99011f60f508bcce2c723baf /addons/payment_stripe | |
| parent | 4a92a183e8631512a8b018eedaf9bf4956ca85e9 (diff) | |
[IMP] *: use named placeholders in translated message
When more than one parameter is present in a message, it helps the
translation to use named placeholder. This way, the order can be
changed. It also helps the comprehension of the message.
Diffstat (limited to 'addons/payment_stripe')
| -rw-r--r-- | addons/payment_stripe/models/payment.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/payment_stripe/models/payment.py b/addons/payment_stripe/models/payment.py index a1a7da752bc..936e8d1c601 100644 --- a/addons/payment_stripe/models/payment.py +++ b/addons/payment_stripe/models/payment.py @@ -253,7 +253,7 @@ class PaymentTransactionStripe(models.Model): _logger.error(error_msg) raise ValidationError(error_msg) elif len(tx) > 1: - error_msg = (_('Stripe: %s orders found for reference %s') % (len(tx), reference)) + error_msg = _('Stripe: %(count)s orders found for reference %(reference)s', count=len(tx), reference=reference) _logger.error(error_msg) raise ValidationError(error_msg) return tx[0] |
