Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/tools/task/todo-sync.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export function syncTaskToTodo(task: Task): TodoInfo | null {
id: task.id,
content: task.subject,
status: todoStatus,
priority: extractPriority(task.metadata),
priority: extractPriority(task.metadata) ?? "medium",
Copy link

Copilot AI Mar 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This changes syncTaskToTodo() so missing/invalid metadata.priority now yields a concrete priority ("medium") instead of undefined. The existing unit tests in src/tools/task/todo-sync.test.ts currently assert priority is undefined for (a) tasks without metadata, (b) tasks without metadata.priority, and (c) invalid priority values, so they will fail unless updated to expect the new default (and/or the desired fallback behavior is adjusted).

Suggested change
priority: extractPriority(task.metadata) ?? "medium",
priority: extractPriority(task.metadata),

Copilot uses AI. Check for mistakes.
};
}

Expand Down
Loading