From 1a77656d8af093b8997637ea56ad16c8bb53e76d Mon Sep 17 00:00:00 2001 From: Andreas Knuth Date: Wed, 7 Aug 2024 13:33:22 +0200 Subject: [PATCH] fix missing id --- bizmatch-server/src/utils.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bizmatch-server/src/utils.ts b/bizmatch-server/src/utils.ts index 86a1a5c..f26d2e0 100644 --- a/bizmatch-server/src/utils.ts +++ b/bizmatch-server/src/utils.ts @@ -35,8 +35,8 @@ export function convertUserToDrizzleUser(user: Partial): DrizzleUser { const { companyLocation, ...restUser } = user; // Ensure all required fields are present - if (!user.id || !user.email || !user.firstname || !user.lastname) { - throw new Error('Missing required fields: id, email, firstname, or lastname'); + if (!user.email || !user.firstname || !user.lastname) { + throw new Error('Missing required fields: email, firstname, or lastname'); } return {