Mongoose document.set() strict option

Viewed 16

I'm using the strict option in a document.set() and I was wondering if setting this flag can change the schema's strict mode. Any thoughts on this?

product.set("badges", product.hasBadges(), { strict: false });
1 Answers

After performing some tests i verified that it does not change the behavior of the schema. I confess that i was afraid to test and mess up our database, but after thinking about it i saw that there would be no problems. Thank you!

Related