mirror of https://github.com/django/django.git
Fixed #3955 -- Handled the case when there is no LOCALE_PATHS setting from [6349]. Thanks, Wang Chun and semenov.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6447 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
fa546d797e
commit
291b81b4e3
2
AUTHORS
2
AUTHORS
|
@ -313,7 +313,7 @@ answer newbie questions, and generally made Django that much better:
|
||||||
Vlado <vlado@labath.org>
|
Vlado <vlado@labath.org>
|
||||||
Milton Waddams
|
Milton Waddams
|
||||||
wam-djangobug@wamber.net
|
wam-djangobug@wamber.net
|
||||||
wangchun <yaohua2000@gmail.com>
|
Wang Chun <wangchun@exoweb.net>
|
||||||
Filip Wasilewski <filip.wasilewski@gmail.com>
|
Filip Wasilewski <filip.wasilewski@gmail.com>
|
||||||
Dan Watson <http://theidioteque.net/>
|
Dan Watson <http://theidioteque.net/>
|
||||||
Chris Wesseling <Chris.Wesseling@cwi.nl>
|
Chris Wesseling <Chris.Wesseling@cwi.nl>
|
||||||
|
|
|
@ -14,7 +14,8 @@ def compile_messages(locale=None):
|
||||||
basedirs = [os.path.join('conf', 'locale'), 'locale']
|
basedirs = [os.path.join('conf', 'locale'), 'locale']
|
||||||
if os.environ.get('DJANGO_SETTINGS_MODULE'):
|
if os.environ.get('DJANGO_SETTINGS_MODULE'):
|
||||||
from django.conf import settings
|
from django.conf import settings
|
||||||
basedirs += settings.LOCALE_PATHS
|
if hasattr(settings, 'LOCALE_PATHS'):
|
||||||
|
basedirs += settings.LOCALE_PATHS
|
||||||
|
|
||||||
# Gather existing directories.
|
# Gather existing directories.
|
||||||
basedirs = set(map(os.path.abspath, filter(os.path.isdir, basedirs)))
|
basedirs = set(map(os.path.abspath, filter(os.path.isdir, basedirs)))
|
||||||
|
|
Loading…
Reference in New Issue