Projet

Général

Profil

0002-python3-deprecate-django.utils.encoding.smart_unicod.patch

Paul Marillonnet, 20 mars 2019 17:02

Télécharger (1,51 ko)

Voir les différences:

Subject: [PATCH 2/2] python3: deprecate django.utils.encoding.smart_unicode
 (#31155)

 src/authentic2/idp/saml/saml2_endpoints.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
src/authentic2/idp/saml/saml2_endpoints.py
36 36
from django.views.decorators.http import require_POST
37 37
from django.contrib.auth import BACKEND_SESSION_KEY, REDIRECT_FIELD_NAME
38 38
from django.conf import settings
39
from django.utils.encoding import smart_unicode
39
from django.utils.encoding import smart_text
40 40
from django.utils.six.moves.urllib.parse import quote, urlencode
41 41
from django.contrib.auth import load_backend
42 42
from django.shortcuts import render, redirect
......
300 300
                    elif value is False:
301 301
                        value = u'false'
302 302
                    else:
303
                        value = smart_unicode(value)
303
                        value = smart_text(value)
304 304
                    value = value.encode('utf-8')
305 305
                    text_node = lasso.MiscTextNode.newWithString(value)
306 306
                    text_node.textChild = True
307
-