From ed62aacbb9906d38a24839dccf0b6dd26f89c53e Mon Sep 17 00:00:00 2001 From: Carson McManus Date: Tue, 30 Apr 2024 08:12:08 -0400 Subject: [PATCH] server: send details of zod validation errors --- server/api/room.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server/api/room.ts b/server/api/room.ts index 7bcc640df..c4169e09c 100644 --- a/server/api/room.ts +++ b/server/api/room.ts @@ -464,7 +464,8 @@ const errorHandler: ErrorRequestHandler = (err: Error, req, res) => { res.status(400).json({ success: false, error: { - name: err.name, + ...err, + message: err.message, }, }); } else {