diff options
author | Petr Viktorin <pviktori@redhat.com> | 2012-07-04 08:52:47 -0400 |
---|---|---|
committer | Martin Kosek <mkosek@redhat.com> | 2012-09-03 18:16:12 +0200 |
commit | a95eaeac8e07b8ccd173b0f408575cc9a0d508fc (patch) | |
tree | 6cd7e09e02d313a3d382d1efbb27588aab27a866 /ipalib/plugins/host.py | |
parent | 4f03aed5e603389bbb149464eee597180470ad70 (diff) | |
download | freeipa.git-a95eaeac8e07b8ccd173b0f408575cc9a0d508fc.tar.gz freeipa.git-a95eaeac8e07b8ccd173b0f408575cc9a0d508fc.tar.xz freeipa.git-a95eaeac8e07b8ccd173b0f408575cc9a0d508fc.zip |
Internationalization for public errors
Currently, we throw many public exceptions without proper i18n.
Wrap natural-language error messages in _() so they can be translated.
In the service plugin, raise NotFound errors using handle_not_found helper
so the error message contains the offending service.
Use ScriptError instead of NotFoundError in bindinstance install.
https://fedorahosted.org/freeipa/ticket/1953
Diffstat (limited to 'ipalib/plugins/host.py')
-rw-r--r-- | ipalib/plugins/host.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ipalib/plugins/host.py b/ipalib/plugins/host.py index 8f6b5262..91b3ce67 100644 --- a/ipalib/plugins/host.py +++ b/ipalib/plugins/host.py @@ -621,7 +621,7 @@ class host_mod(LDAPUpdate): # Once a principal name is set it cannot be changed if 'cn' in entry_attrs: - raise errors.ACIError(info='cn is immutable') + raise errors.ACIError(info=_('cn is immutable')) if 'locality' in entry_attrs: entry_attrs['l'] = entry_attrs['locality'] del entry_attrs['locality'] |