mirror of
https://github.com/khoaliber/khoj.git
synced 2026-03-07 21:29:13 +00:00
Handle case when properties field isn't present in the page
This commit is contained in:
@@ -223,7 +223,8 @@ class NotionToEntries(TextToEntries):
|
|||||||
except Exception as e:
|
except Exception as e:
|
||||||
logger.error(f"Error getting page {page_id}: {e}", exc_info=True)
|
logger.error(f"Error getting page {page_id}: {e}", exc_info=True)
|
||||||
return None, None
|
return None, None
|
||||||
properties = page["properties"]
|
properties = page.get("properties", {})
|
||||||
|
|
||||||
title_field = "title"
|
title_field = "title"
|
||||||
if "Title" in properties:
|
if "Title" in properties:
|
||||||
title_field = "Title"
|
title_field = "Title"
|
||||||
|
|||||||
Reference in New Issue
Block a user