diff --git a/src/common/zeroconf/client_zeroconf.py b/src/common/zeroconf/client_zeroconf.py index e61ee462b..f24d041a8 100644 --- a/src/common/zeroconf/client_zeroconf.py +++ b/src/common/zeroconf/client_zeroconf.py @@ -756,7 +756,7 @@ class ClientZeroconf: if to is None: # Can’t send undirected stanza over Zeroconf. return -1 - to = gajim.get_jid_without_resource(to) + to = to.getStripped() stanza.setFrom(self.roster.zeroconf.name) try: @@ -801,7 +801,7 @@ class ClientZeroconf: """ Generate a random id """ - return ''.join(Random().sample(string.letters + string.digits, 6)) + return ''.join(Random().sample(string.ascii_letters + string.digits, 6)) def RegisterDisconnectHandler(self, handler): """