Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

todo_widget: Add `type`` as Optional in `new_task_inbound_data_schema`.

sujal shahfcbb1cd55861
diff --git a/web/src/todo_widget.ts b/web/src/todo_widget.ts
index 7f8068c0564..8a65ead7c5c 100644
--- a/web/src/todo_widget.ts
+++ b/web/src/todo_widget.ts
@@ -31,7 +31,7 @@ const todo_widget_inbound_data = z.intersection(
);
const new_task_inbound_data_schema = z.object({
- type: z.literal("new_task"),
+ type: z.literal("new_task").optional(),
key: z.number().int().nonnegative().max(MAX_IDX),
task: z.string(),
desc: z.string(),