iotsensor fixed but session valid broken

This commit is contained in:
newtbot
2024-01-25 03:26:56 +08:00
parent 7403f66c8a
commit 057fbe2afb
19 changed files with 173 additions and 237 deletions

View File

@ -11,11 +11,14 @@ router.get("/me", async function (req, res, next) {
if (!user) {
let error = new Error("User not found");
error.status = 400;
console.log(error);
return next(error);
}
if (user){
res.json({
user: user,
});
}
} catch (error) {
next(error);
}