fix: bad error handling when checking bookmarks storage

This commit is contained in:
mathieui 2021-03-14 12:26:28 +01:00
parent 6b0d393cf8
commit cdae238d76

View file

@ -1713,9 +1713,9 @@ class Core:
if not self.xmpp.anon and config.get('use_remote_bookmarks'):
try:
await self.bookmarks.get_remote(self.xmpp, self.information)
except IqError as iq:
type_ = iq['error']['type']
condition = iq['error']['condition']
except IqError as error:
type_ = error.iq['error']['type']
condition = error.iq['error']['condition']
if not (type_ == 'cancel' and condition == 'item-not-found'):
self.information(
'Unable to fetch the remote'