diff options
Diffstat (limited to 'django/urls/resolvers.py')
-rw-r--r-- | django/urls/resolvers.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/urls/resolvers.py b/django/urls/resolvers.py index 26c9884e18..633eba272c 100644 --- a/django/urls/resolvers.py +++ b/django/urls/resolvers.py @@ -338,7 +338,7 @@ class LocalePrefixPattern: @property def regex(self): # This is only used by reverse() and cached in _reverse_dict. - return re.compile(self.language_prefix) + return re.compile(re.escape(self.language_prefix)) @property def language_prefix(self): |