Fix missing argument error for database file. (Thank you. roughnecks).

This commit is contained in:
Schimon Jehudah, Adv. 2024-11-17 18:30:29 +02:00
parent 09d50b9636
commit 9e4d6f0d32

View file

@ -186,7 +186,7 @@ class UtilitiesData:
if not os.path.exists(filename_items) or os.path.getsize(filename_items) in (0, 13): if not os.path.exists(filename_items) or os.path.getsize(filename_items) in (0, 13):
iq = await XmppPubsub.get_node_items(xmpp_instance, jabber_id, node_id) iq = await XmppPubsub.get_node_items(xmpp_instance, jabber_id, node_id)
if isinstance(iq, Iq): if isinstance(iq, Iq):
entries_cache_node = UtilitiesData.extract_iq_items_extra(iq, jabber_id) entries_cache_node = UtilitiesData.extract_iq_items_extra(db_file, iq, jabber_id)
data_items = {node_type : entries_cache_node} data_items = {node_type : entries_cache_node}
UtilitiesData.save_to_toml(filename_items, data_items) UtilitiesData.save_to_toml(filename_items, data_items)
return ['fine', iq] # TODO Remove this line return ['fine', iq] # TODO Remove this line
@ -223,7 +223,7 @@ class UtilitiesData:
iq = await XmppPubsub.get_node_item( iq = await XmppPubsub.get_node_item(
xmpp_instance, jabber_id, node_id, url_hash) xmpp_instance, jabber_id, node_id, url_hash)
if isinstance(iq, Iq): if isinstance(iq, Iq):
entries_iq = UtilitiesData.extract_iq_items_extra(iq, jabber_id) entries_iq = UtilitiesData.extract_iq_items_extra(db_file, iq, jabber_id)
entries_cache_node_new += entries_iq entries_cache_node_new += entries_iq
else: else:
# TODO # TODO