# HG changeset patch # User souliane # Date 1383840100 -3600 # Node ID 712e3782af1270b18e2e4c6a58203a4e6a802032 # Parent 4e691a231763cfaf219199d0ac8f4edfb9b129d9 plugin misc_account: added method getNewAccountDomain diff -r 4e691a231763 -r 712e3782af12 src/plugins/plugin_misc_account.py --- a/src/plugins/plugin_misc_account.py Thu Nov 07 16:58:20 2013 +0100 +++ b/src/plugins/plugin_misc_account.py Thu Nov 07 17:01:40 2013 +0100 @@ -87,6 +87,7 @@ info(_(u"Plugin Account initialization")) self.host = host host.bridge.addMethod("registerSatAccount", ".plugin", in_sign='sss', out_sign='', method=self._registerAccount, async=True) + host.bridge.addMethod("getNewAccountDomain", ".plugin", in_sign='', out_sign='s', method=self._getNewAccountDomain, async=False) if not self._prosody_path: paths = which(_PROSODYCTL) if not paths: @@ -185,3 +186,8 @@ d = sendmail(_email_host, _email_from, _REG_ADMIN_EMAIL, msg.as_string()) d.addCallbacks(email_ok, email_ko) + + def _getNewAccountDomain(self): + """@return: the domain that will be set to new account""" + return _NEW_ACCOUNT_DOMAIN +