Little tip about version control in Mongoose
This post was published 10 years ago so it may be outdated.
Did you ever encountered this message when working with Mongoose?
VersionError: No matching document found.
This is a good explanation about version control in Mongoose, what it is and why it is useful.
If you are inserting content into the database with MongoDB driver and updating it using Mongoose, be careful! __v won’t be set and if any of your document attributes is an array you can get easily in trouble.
No replies on “Little tip about version control in Mongoose”