Good day,Basir:
Appriciate for your sharring in Youtube, and I have a question to asked.
In the lesson 25 of Amazona, I tried to ‘sign up’ a new account, the web-brower show me “User validation failed: isAdmin: Path `isAdmin` is required.” It is caused by ‘isAdmin: { …, required: true}’ which in userModal.js as I knew.
My question is when I singin to the weibsite, it would res.send ({…,isAdmin: user.isAdmin,…}) and signup will send ,too.
Why the error msg response on signup only? When I modify require to “false”, it sign-up successfully.
Could you clean this confussion to me ?

Best Regards

Bassir Answered question October 13, 2022