summaryrefslogtreecommitdiff
path: root/horizon/exceptions.py
diff options
context:
space:
mode:
authorBrooklyn Chen <brooklyn.chen@canonical.com>2013-05-14 14:05:42 +0800
committerBrooklyn Chen <brooklyn.chen@canonical.com>2013-05-18 15:13:54 +0800
commit08e6ed7392aa9d510833dee5b468140de10c22a6 (patch)
tree2a362ef616fc8c65fc8b2387bb259c0c384594d5 /horizon/exceptions.py
parentd17fd51359ef915e59e053401dec0e8a952dfbe8 (diff)
downloadhorizon-08e6ed7392aa9d510833dee5b468140de10c22a6.tar.gz
Use ugettext_lazy instead of ugettext.
We should use ugettext_lazy to let users in different languages get correct translation.Though in views or similar places we can use ugettext with no problems, we should make code style consistent. This also fix the issues that the django proxy objects appear on the launching instance page instead of translated strings. Now the translated quota strings are handled correctly. Fixes: bug #1178722 Change-Id: I76f0d31e6546d70e5ece7e86a06f7eefd04861d2
Diffstat (limited to 'horizon/exceptions.py')
-rw-r--r--horizon/exceptions.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/horizon/exceptions.py b/horizon/exceptions.py
index 0402d60a6..e2da6d427 100644
--- a/horizon/exceptions.py
+++ b/horizon/exceptions.py
@@ -25,7 +25,7 @@ import sys
from django.contrib.auth import logout
from django.http import HttpRequest
from django.utils import termcolors
-from django.utils.translation import ugettext as _
+from django.utils.translation import ugettext_lazy as _
from django.views.debug import SafeExceptionReporterFilter, CLEANSED_SUBSTITUTE
from horizon import messages