Code quality

This commit is contained in:
Yohann D'ANELLO
2020-04-25 03:14:01 +02:00
committed by Valentin Samir
parent 4129687e41
commit 9cd44aa8aa
3 changed files with 12 additions and 2 deletions

View File

@ -24,7 +24,11 @@ try:
from django.utils.encoding import python_2_unicode_compatible
from django.utils.translation import ugettext as _
except ImportError:
def python_2_unicode_compatible(f): return f
def python_2_unicode_compatible(func):
"""
We use Django >= 3.0 with Python >= 3.4, we don't need Python 2 compatibility.
"""
return func
from django.utils.translation import gettext as _
from django.utils.safestring import mark_safe
try: