I am new to Mongo and use Mongoose as ORM.
To register a user, I use email as unique. I want to check if the letter is really in use, and if not, do something (maybe save, maybe the next registration step, etc.).
Sorry for what seems like a simple question, but I did not find an answer for him.
If it is not upsert. This means that you are inserting a document, even if I'm not quite ready ...
source
share