From e433e07a8d50e71c885bcbb58933efd3a992bcc4 Mon Sep 17 00:00:00 2001 From: Adrian Holovaty Date: Thu, 27 Jul 2006 16:38:32 +0000 Subject: [PATCH] Fixed #2408 -- Added get_language_from_request() to trans_null.py. Thanks, ubernostrum git-svn-id: http://code.djangoproject.com/svn/django/trunk@3458 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/utils/translation/trans_null.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/django/utils/translation/trans_null.py b/django/utils/translation/trans_null.py index 0eb2b5a89a..75ad573357 100644 --- a/django/utils/translation/trans_null.py +++ b/django/utils/translation/trans_null.py @@ -25,3 +25,6 @@ def to_locale(language): return language[:p].lower()+'_'+language[p+1:].upper() else: return language.lower() + +def get_language_from_request(request): + return settings.LANGUAGE_CODE