mirror of
https://github.com/django/django.git
synced 2024-12-25 02:26:12 +00:00
Fixed #7831: be case-insensitive when in get_language_from_request
.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8561 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
ddb3cdd514
commit
6a5cc9e7f6
@ -381,7 +381,7 @@ def get_language_from_request(request):
|
||||
|
||||
for lang, dirname in ((accept_lang, normalized),
|
||||
(accept_lang.split('-')[0], normalized.split('_')[0])):
|
||||
if lang not in supported:
|
||||
if lang.lower() not in supported:
|
||||
continue
|
||||
langfile = os.path.join(globalpath, dirname, 'LC_MESSAGES',
|
||||
'django.mo')
|
||||
|
Loading…
Reference in New Issue
Block a user