From 02e8d44e9d7ea0ed4d31ea400ae49d864afa4acf Mon Sep 17 00:00:00 2001 From: Bernice Uwituze <113672733+berniceu@users.noreply.github.com> Date: Mon, 2 Dec 2024 12:40:21 +0200 Subject: [PATCH] Fix signup (#166) --- src/resolvers/applicationStageResolver.ts | 4 ++-- src/validations/createUser.validation.ts | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/resolvers/applicationStageResolver.ts b/src/resolvers/applicationStageResolver.ts index e5b3251a..b3263df1 100644 --- a/src/resolvers/applicationStageResolver.ts +++ b/src/resolvers/applicationStageResolver.ts @@ -618,13 +618,13 @@ export const applicationStageResolvers: any = { switch (applicantStage) { case "Technical Assessment": await TechnicalAssessment.updateOne( - { applicantId, status: "No action" }, + { applicantId }, { $set: { score } } ); break; case "Interview Assessment": await InterviewAssessment.updateOne( - { applicantId, status: "No action" }, + { applicantId }, { $set: { interviewScore: score } } ); break; diff --git a/src/validations/createUser.validation.ts b/src/validations/createUser.validation.ts index 4fa0384e..e2cf1118 100644 --- a/src/validations/createUser.validation.ts +++ b/src/validations/createUser.validation.ts @@ -9,6 +9,7 @@ interface UserLoggedInput { gender: String; country: String; code: String; + bio: String; } export const validateUserLogged = Joi.object({ @@ -37,4 +38,5 @@ export const validateUserLogged = Joi.object({ telephone: Joi.string(), country: Joi.string(), code: Joi.string().min(2).max(4).message('Code must be between 2 and 4 characters long.'), + bio: Joi.string().optional() });