Browse files

Fixed #13234 -- Rejiggered the imports in the translation utils . Tha…

…nks to roklenardic and Spark23 for their reports, and to Alex for his suggestion on a potential fix.

git-svn-id: bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
1 parent aa53876 commit 7d2568210894d97a419676d311ef18ecc565b8ec @freakboy3742 freakboy3742 committed Mar 29, 2010
Showing with 3 additions and 4 deletions.
  1. +3 −4 django/utils/translation/
@@ -1,10 +1,8 @@
Internationalization support.
-from django.conf import settings
from django.utils.encoding import force_unicode
from django.utils.functional import lazy, curry
-from django.utils.translation import trans_real, trans_null
__all__ = ['gettext', 'gettext_noop', 'gettext_lazy', 'ngettext',
@@ -28,10 +26,11 @@ def delayed_loader(real_name, *args, **kwargs):
that modules can use the translation bits without actually requiring
Django's settings bits to be configured before import.
+ from django.conf import settings
if settings.USE_I18N:
- trans = trans_real
+ from django.utils.translation import trans_real as trans
- trans = trans_null
+ from django.utils.translation import trans_null as trans
# Make the originally requested function call on the way out the door.
return getattr(trans, real_name)(*args, **kwargs)

0 comments on commit 7d25682

Please sign in to comment.