diff --git a/sat/core/xmpp.py b/sat/core/xmpp.py index d78974db..da5c4e43 100644 --- a/sat/core/xmpp.py +++ b/sat/core/xmpp.py @@ -849,6 +849,9 @@ class SatXMPPClient(SatXMPPEntity, wokkel_client.XMPPClient): xml_tools.quickNote(host_app, self, msg, _("Security notice"), level = C.XMLUI_DATA_LVL_WARNING) + @property + def server_jid(self): + return jid.JID(self.jid.host) def _getPluginsList(self): for p in self.host_app.plugins.values(): @@ -1001,6 +1004,11 @@ class SatXMPPComponent(SatXMPPEntity, component.Component): component.Component.__init__(self, host, port, component_jid.full(), password) SatXMPPEntity.__init__(self, host_app, profile, max_retries) + @property + def server_jid(self): + # FIXME: not the best way to get server jid, maybe use config option? + return jid.JID(self.jid.host.split(".", 1)[-1]) + def _buildDependencies(self, current, plugins, required=True): """build recursively dependencies needed for a plugin