fix: code review cleanup

- Fixed TypeScript exactOptionalPropertyTypes errors in chat components
- Removed console.error statements (errors are handled via state)
- Fixed type compatibility issues with undefined vs null values
- All chat-related files now pass strict TypeScript checks
This commit is contained in:
Jason Woltje
2026-01-29 23:36:01 -06:00
parent 08938dc735
commit 69bdfa5df1
4 changed files with 17 additions and 14 deletions

View File

@@ -54,9 +54,9 @@ export const ConversationSidebar = forwardRef<ConversationSidebarRef, Conversati
return {
id: idea.id,
title: idea.title,
projectId: idea.projectId,
updatedAt: idea.updatedAt,
title: idea.title ?? null,
projectId: idea.projectId ?? null,
updatedAt: idea.updatedAt ?? null,
messageCount,
};
}, []);
@@ -84,7 +84,7 @@ export const ConversationSidebar = forwardRef<ConversationSidebarRef, Conversati
} catch (err) {
const errorMsg = err instanceof Error ? err.message : "Failed to load conversations";
setError(errorMsg);
console.error("Error fetching conversations:", err);
// Error is set to state and will be displayed to the user
} finally {
setIsLoading(false);
}