Fix imports

transports_nb was renamed in nbxmpp
This commit is contained in:
Philipp Hörist 2019-03-04 13:49:03 +01:00
parent 74c5f3d0e9
commit 1827249653
3 changed files with 5 additions and 5 deletions

View File

@ -1023,7 +1023,7 @@ class Connection(CommonConnection, ConnectionHandlers):
if self._proxy and self._proxy['type'] == 'bosh':
# with BOSH, we can't do TLS negotiation with <starttls>, we do only "plain"
# connection and TLS with handshake right after TCP connecting ("ssl")
scheme = nbxmpp.transports_nb.urisplit(self._proxy['bosh_uri'])[0]
scheme = nbxmpp.transports.urisplit(self._proxy['bosh_uri'])[0]
if scheme == 'https':
connection_types = ['ssl']
else:

View File

@ -31,9 +31,9 @@ from nbxmpp import simplexml
from nbxmpp.structs import StanzaHandler
from nbxmpp.plugin import PlugIn
from nbxmpp.idlequeue import IdleObject
from nbxmpp.transports_nb import DATA_RECEIVED
from nbxmpp.transports_nb import DATA_SENT
from nbxmpp.transports_nb import DATA_ERROR
from nbxmpp.transports import DATA_RECEIVED
from nbxmpp.transports import DATA_SENT
from nbxmpp.transports import DATA_ERROR
from gajim.common import app
from gajim.common.zeroconf import zeroconf

View File

@ -465,7 +465,7 @@ class ConnectionZeroconf(CommonConnection, ConnectionHandlersZeroconf):
def _event_dispatcher(self, realm, event, data):
CommonConnection._event_dispatcher(self, realm, event, data)
if realm == '':
if event == nbxmpp.transports_nb.DATA_ERROR:
if event == nbxmpp.transports.DATA_ERROR:
thread_id = data[1]
frm = data[0]
session = self.get_or_create_session(frm, thread_id)