fix: briefing pipeline — pass user_id to is_caldav_configured, use p.title not p.get()
This commit is contained in:
@@ -80,7 +80,7 @@ async def _gather_internal(user_id: int) -> dict:
|
||||
# Calendar events today
|
||||
calendar_events = []
|
||||
try:
|
||||
if is_caldav_configured():
|
||||
if is_caldav_configured(user_id):
|
||||
events = await list_events(user_id, start=today, end=today)
|
||||
calendar_events = [
|
||||
f"{e.get('summary', 'Event')} at {e.get('dtstart', 'unknown time')}"
|
||||
@@ -94,7 +94,7 @@ async def _gather_internal(user_id: int) -> dict:
|
||||
try:
|
||||
projects = await list_projects(user_id)
|
||||
for p in projects[:5]:
|
||||
projects_summary.append(p.get("title", "Untitled project"))
|
||||
projects_summary.append(p.title or "Untitled project")
|
||||
except Exception:
|
||||
logger.warning("Failed to gather projects for briefing", exc_info=True)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user