diff --git a/payments/dotpay/__init__.py b/payments/dotpay/__init__.py index f4636e965..78c491cc2 100644 --- a/payments/dotpay/__init__.py +++ b/payments/dotpay/__init__.py @@ -81,9 +81,9 @@ def get_hidden_fields(self, payment): "currency": payment.currency, "description": payment.description, "lang": self.lang, - "ignore_last_payment_channel": "1" - if self.ignore_last_payment_channel - else "0", + "ignore_last_payment_channel": ( + "1" if self.ignore_last_payment_channel else "0" + ), "ch_lock": "1" if self.lock else "0", "URL": payment.get_success_url(), "URLC": self.get_return_url(payment), diff --git a/payments/sofort/__init__.py b/payments/sofort/__init__.py index 9bcf30fa9..1d1d65101 100644 --- a/payments/sofort/__init__.py +++ b/payments/sofort/__init__.py @@ -58,9 +58,11 @@ def get_form(self, payment, data=None): "interface_version": "django-payments", "amount": payment.total, "currency": payment.currency, - "description": payment.description - if len(payment.description) <= 40 - else (payment.description[:37] + "..."), + "description": ( + payment.description + if len(payment.description) <= 40 + else (payment.description[:37] + "...") + ), "success_url": self.get_return_url(payment), "abort_url": self.get_return_url(payment), "customer_protection": "0", diff --git a/payments/urls.py b/payments/urls.py index b1decdaec..deb70fcd5 100644 --- a/payments/urls.py +++ b/payments/urls.py @@ -2,6 +2,7 @@ This module is responsible for automatic processing of provider callback data (asynchronous transaction updates). """ + from __future__ import annotations from django.db.transaction import atomic diff --git a/testapp/testapp/asgi.py b/testapp/testapp/asgi.py index 9aa05edbe..bd147018a 100644 --- a/testapp/testapp/asgi.py +++ b/testapp/testapp/asgi.py @@ -6,6 +6,7 @@ For more information on this file, see https://docs.djangoproject.com/en/3.2/howto/deployment/asgi/ """ + from __future__ import annotations import os diff --git a/testapp/testapp/wsgi.py b/testapp/testapp/wsgi.py index 2b902f76c..ac5739e97 100644 --- a/testapp/testapp/wsgi.py +++ b/testapp/testapp/wsgi.py @@ -6,6 +6,7 @@ For more information on this file, see https://docs.djangoproject.com/en/3.2/howto/deployment/wsgi/ """ + from __future__ import annotations import os