ticket 1705 - internationalize help topics

* Wrap each topic description in _()

* Replace the use of if 'topic' in dir(module) with the more
  Pythonic and efficient getattr(module, 'topic', None)

* Make sure to invoke unicode on the value returned from _()
  otherwise you'll get a GettextFactory instance, not a string

* Clean up trailing whitespace errors
This commit is contained in:
John Dennis
2011-08-24 17:27:32 -04:00
committed by Rob Crittenden
parent f4ad749126
commit a4fadbfe63
7 changed files with 9 additions and 11 deletions

View File

@@ -45,7 +45,7 @@ from ipalib import api, errors
from ipalib.plugins.baseldap import *
from ipalib import _, ngettext
topic = ('hbac', 'Host based access control commands')
topic = ('hbac', _('Host based access control commands'))
class hbacsvcgroup(LDAPObject):
"""