Fix further errors.
This commit is contained in:
parent
9e4d6f0d32
commit
519c277ea6
1 changed files with 7 additions and 7 deletions
|
@ -1393,7 +1393,7 @@ class HttpInstance:
|
|||
'name' : name,
|
||||
'instances' : instances}
|
||||
xmpp_instance = accounts[jabber_id]
|
||||
payload = Syndication.create_rfc4287_entry(entry_new)
|
||||
payload = UtilitiesSyndication.create_rfc4287_entry(entry_new)
|
||||
iq = await XmppPubsub.publish_node_item(
|
||||
xmpp_instance, jabber_id, node_id, item_id, payload)
|
||||
#await iq.send(timeout=15)
|
||||
|
@ -1747,9 +1747,9 @@ class HttpInstance:
|
|||
if exist:
|
||||
# TODO Perhaps adding a paragraph with "your tags" and "who else has tagged this link"
|
||||
# and keep the (5 item) limit.
|
||||
#entry = Syndication.extract_items(item_payload)
|
||||
#entry = UtilitiesSyndication.extract_items(item_payload)
|
||||
# NOTE Display only 5 items, as all the other tags appear at the list of "Related tags".
|
||||
entry = Syndication.extract_items(item_payload, limit=True)
|
||||
entry = UtilitiesSyndication.extract_items(item_payload, limit=True)
|
||||
if entry:
|
||||
#url_hash = iq_item['id']
|
||||
url_hash = UtilitiesCryptography.hash_url_to_md5(entry['link'])
|
||||
|
@ -1913,7 +1913,7 @@ class HttpInstance:
|
|||
message = 'Information for URL {}'.format(url)
|
||||
description = 'Bookmark properties'
|
||||
xmpp_instance = accounts[jabber_id]
|
||||
payload = Syndication.create_rfc4287_entry(entry)
|
||||
payload = UtilitiesSyndication.create_rfc4287_entry(entry)
|
||||
# TODO Add try/except for IQ
|
||||
print('Publish item')
|
||||
# TODO Check.
|
||||
|
@ -2070,7 +2070,7 @@ class HttpInstance:
|
|||
if exist:
|
||||
# TODO Add a check: if iq_item['id'] == url_hash:
|
||||
entries = []
|
||||
entry = Syndication.extract_items(item_payload)
|
||||
entry = UtilitiesSyndication.extract_items(item_payload)
|
||||
instances = DatabaseSQLite.get_entry_instances_by_url_hash(db_file, url_hash)
|
||||
entry['instances'] = instances
|
||||
entry['jid'] = jabber_id
|
||||
|
@ -2142,7 +2142,7 @@ class HttpInstance:
|
|||
if exist:
|
||||
# TODO Add a check: if iq_item['id'] == url_hash:
|
||||
entries = []
|
||||
entry = Syndication.extract_items(item_payload)
|
||||
entry = UtilitiesSyndication.extract_items(item_payload)
|
||||
instances = DatabaseSQLite.get_entry_instances_by_url_hash(db_file, url_hash)
|
||||
entry['instances'] = instances
|
||||
entry['jid'] = jabber_id
|
||||
|
@ -2239,7 +2239,7 @@ class HttpInstance:
|
|||
if exist:
|
||||
path = 'edit'
|
||||
description = 'Edit an existing bookmark'
|
||||
entry = Syndication.extract_items(item_payload)
|
||||
entry = UtilitiesSyndication.extract_items(item_payload)
|
||||
entry['instances'] = DatabaseSQLite.get_entry_instances_by_url_hash(db_file, url_hash)
|
||||
print(jabber_id)
|
||||
print(entry['tags'])
|
||||
|
|
Loading…
Reference in a new issue