diff --git a/length_notifier/length_notifier.py b/length_notifier/length_notifier.py index ae35266..82956c7 100644 --- a/length_notifier/length_notifier.py +++ b/length_notifier/length_notifier.py @@ -90,11 +90,11 @@ class LengthNotifierPlugin(GajimPlugin): # Not restricted to any JIDs return True - current_jid = JID(jid) + current_jid = JID.from_string(jid) allowed_jids = self.config['JIDS'].split(',') for allowed_jid in allowed_jids: try: - address = JID(allowed_jid.strip()) + address = JID.from_string(allowed_jid.strip()) except Exception as error: log.debug('Error parsing JID: %s (%s)' % (error, allowed_jid)) continue diff --git a/omemo/modules/omemo.py b/omemo/modules/omemo.py index 90fede3..b39cb02 100644 --- a/omemo/modules/omemo.py +++ b/omemo/modules/omemo.py @@ -267,7 +267,7 @@ class OMEMO(BaseModule): contact = app.contacts.get_gc_contact(self._account, room_jid, resource) if contact is not None: - return JID(contact.jid).bare + return JID.from_string(contact.jid).bare self._log.info('Groupchat: Last resort trying to find SID in DB') from_jid = self.backend.storage.getJidFromDevice(properties.omemo.sid) diff --git a/openpgp/pgpplugin.py b/openpgp/pgpplugin.py index 62692cf..4ca0b03 100644 --- a/openpgp/pgpplugin.py +++ b/openpgp/pgpplugin.py @@ -140,7 +140,7 @@ class OpenPGPPlugin(GajimPlugin): keys = app.connections[account].get_module('OpenPGP').get_keys( jid, only_trusted=False) if not keys: - con.get_module('OpenPGP').request_keylist(JID(jid)) + con.get_module('OpenPGP').request_keylist(JID.from_string(jid)) ErrorDialog( _('No OpenPGP key'), _('We didnt receive a OpenPGP key from this contact.')) diff --git a/tictactoe/plugin.py b/tictactoe/plugin.py index 112bb3e..cbac350 100644 --- a/tictactoe/plugin.py +++ b/tictactoe/plugin.py @@ -254,7 +254,7 @@ class TicTacToeSession(): self.conn = conn self.jid = jid self.type_ = type_ - self.resource = jid.resource() + self.resource = jid.resource if thread_id: self.received_thread_id = True