jp: fixed bad call to quit

This commit is contained in:
Goffi 2018-09-14 16:44:34 +02:00
commit aa10a033b9

View file

@ -467,7 +467,7 @@ class Jp(object):
from lxml import etree
except ImportError:
self.disp(u"lxml module must be installed to use http(s) scheme, please install it with \"pip install lxml\"", error=True)
self.host.quit(1)
self.quit(1)
import urllib2
parser = etree.HTMLParser()
try:
@ -479,7 +479,7 @@ class Jp(object):
links = root.xpath("//link[@rel='alternate' and starts-with(@href, 'xmpp:')]")
if not links:
self.disp(u'Could not find alternate "xmpp:" URI, can\'t find associated XMPP PubSub node/item', error=True)
self.host.quit(1)
self.quit(1)
xmpp_uri = links[0].get('href')
return xmpp_uri