diff --git a/moulinette/core.py b/moulinette/core.py index 0dc3c1f8..6bb03a1b 100644 --- a/moulinette/core.py +++ b/moulinette/core.py @@ -372,7 +372,7 @@ class MoulinetteSignals(object): Keyword arguments: - authenticator -- The authenticator object to use - - help -- A help message for the authenticator + - help -- The translation key of the authenticator's help message Returns: The authenticator object @@ -380,10 +380,6 @@ class MoulinetteSignals(object): """ if authenticator.is_authenticated: return authenticator - - # Retrieve help translation since it's not loaded yet - if help: - help = m18n.n(help) return self._authenticate(authenticator, help) def prompt(self, message, is_password=False, confirm=False): diff --git a/moulinette/interfaces/cli.py b/moulinette/interfaces/cli.py index 270d7246..07cdced0 100644 --- a/moulinette/interfaces/cli.py +++ b/moulinette/interfaces/cli.py @@ -218,7 +218,7 @@ class Interface(BaseInterface): """ # TODO: Allow token authentication? - msg = help or m18n.g('password') + msg = m18n.n(help) if help else m18n.g('password') return authenticator(password=self._do_prompt(msg, True, False, color='yellow'))