Browse files

Merge pull request #49 from willkg/dev-languages-fix

Fix DEV_LANGUAGES
  • Loading branch information...
2 parents 2e845d5 + 6bd39f4 commit faca9a7610720d2262612da01e709126042a8298 @willkg willkg committed Apr 10, 2013
Showing with 6 additions and 0 deletions.
  1. +6 −0 funfactory/settings_base.py
View
6 funfactory/settings_base.py
@@ -89,6 +89,7 @@
# testing the localization on the dev server.
import glob
import itertools
+DEV_LANGUAGES = None
try:
DEV_LANGUAGES = [
os.path.basename(loc).replace('_', '-')
@@ -97,6 +98,11 @@
if (os.path.isdir(loc) and os.path.basename(loc) != 'templates')
]
except OSError:
+ pass
+
+# If the locale/ directory isn't there or it's empty, we make sure that
+# we always have at least 'en-US'.
+if not DEV_LANGUAGES:
DEV_LANGUAGES = ('en-US',)
# On stage/prod, the list of accepted locales is manually maintained. Only

0 comments on commit faca9a7

Please sign in to comment.