diff --git a/src/routes/application.ts b/src/routes/application.ts index 5ae2e499..0a9e4edc 100644 --- a/src/routes/application.ts +++ b/src/routes/application.ts @@ -329,10 +329,10 @@ router.post("/chat/update/status",authenticate(["counselor","teacher"]), async ( return res.status(455).send("Error: Application does not exist"); } if(chat_status === true){ - return res.status(200).send("true"); + return res.status(200).json({chat_status: true}); } else{ - return res.status(200).send("false"); + return res.status(200).json({chat_status: false}); } } catch (err) { console.log(err) diff --git a/src/routes/mentor.ts b/src/routes/mentor.ts index b0332586..2240d5a0 100644 --- a/src/routes/mentor.ts +++ b/src/routes/mentor.ts @@ -25,7 +25,7 @@ router.post("/update/available", authenticate(["counselor", "teacher"]), async ( return res.status(422).send("422 Unprocessable Entity: Missing credentials"); } const mentor_available = await MentHasFunc.update_mentor_info_available(uuid, available); - return res.status(200).send(mentor_available); + return res.status(200).json({mentor_available: mentor_available}); } catch (err) { return res.status(500).send("Internal Server Error"); }