mirror of
https://gitlab.com/bashrc2/epicyon
synced 2026-11-01 10:24:46 +00:00
Check that fields are strings
This commit is contained in:
1 parent
88501572de
commit
aabd319d3d
1 file changed
+6
-2
@@ -514,10 +514,14 @@ def _store_content_labels_base(base_dir: str, nickname: str, domain: str,
|
||||
map_links: list[str] = []
|
||||
published = None
|
||||
if has_object_dict(post_json_object):
|
||||
if 'content' in post_json_object['object']:
|
||||
if 'content' in post_json_object['object'] and \
|
||||
'published' in post_json_object['object']:
|
||||
published = post_json_object['object']['published']
|
||||
post_content = post_json_object['object']['content']
|
||||
map_links += get_map_links_from_post_content(post_content, session)
|
||||
if isinstance(published, str) and \
|
||||
isinstance(post_content, str):
|
||||
map_links += \
|
||||
get_map_links_from_post_content(post_content, session)
|
||||
# get geolocation from labels
|
||||
location_str = get_location_from_post(post_json_object)
|
||||
if location_str:
|
||||
|
||||
Reference in new issue
Block a user