diff options
| author | Jannis Leidel <jannis@leidel.info> | 2012-02-04 18:43:20 +0000 |
|---|---|---|
| committer | Jannis Leidel <jannis@leidel.info> | 2012-02-04 18:43:20 +0000 |
| commit | ef4d84d11ab9357d9c6e35b2a3a0a9d4fb310075 (patch) | |
| tree | 13f58a9d6e94a2f0169271f419abfec6b9a2df92 /django | |
| parent | 878cc62bd49db0800e132051252b368acdeaf55a (diff) | |
Fixed #17555 -- Added support for a missing trailing slash when redirecting based on the browser language. Thanks, neaf.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17443 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django')
| -rw-r--r-- | django/utils/translation/trans_real.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/utils/translation/trans_real.py b/django/utils/translation/trans_real.py index 28d20127c8..419b3809e7 100644 --- a/django/utils/translation/trans_real.py +++ b/django/utils/translation/trans_real.py @@ -38,7 +38,7 @@ accept_language_re = re.compile(r''' (?:\s*,\s*|$) # Multiple accepts per header. ''', re.VERBOSE) -language_code_prefix_re = re.compile(r'^/([\w-]+)/') +language_code_prefix_re = re.compile(r'^/([\w-]+)(/|$)') def to_locale(language, to_lower=False): """ |
