Removed unneeded iri_to_uri() call in reverse().
_reverse_with_prefix() already quotes using a stricter subset of the safe characters used by iri_to_uri().
This commit is contained in:
parent
342a41740d
commit
75d2af2c89
|
@ -2,7 +2,6 @@ from urllib.parse import urlsplit, urlunsplit
|
|||
|
||||
from asgiref.local import Local
|
||||
|
||||
from django.utils.encoding import iri_to_uri
|
||||
from django.utils.functional import lazy
|
||||
from django.utils.translation import override
|
||||
|
||||
|
@ -84,7 +83,7 @@ def reverse(viewname, urlconf=None, args=None, kwargs=None, current_app=None):
|
|||
if ns_pattern:
|
||||
resolver = get_ns_resolver(ns_pattern, resolver, tuple(ns_converters.items()))
|
||||
|
||||
return iri_to_uri(resolver._reverse_with_prefix(view, prefix, *args, **kwargs))
|
||||
return resolver._reverse_with_prefix(view, prefix, *args, **kwargs)
|
||||
|
||||
|
||||
reverse_lazy = lazy(reverse, str)
|
||||
|
|
Loading…
Reference in New Issue