Mongoose 5.13.9 released. Legacy release for v5.x with a few bug fixes:
🛠️ Avoid setting empty array on lean document when populate result is undefined
🛠️ Make depopulate() handle paths under document arrays
Full changelog: github.com/Automattic/mongoo…#NodeJS#MongoDB#JavaScript
The first Nuxt conference is happening 💣
Join the Nuxt Nation today!
Date: 15th & 16th September 2021
Tickets: FREE ✅
Among many amazing speakers, get the chance to have a Q&A with Sebastien Chopin and Evan You!
nuxtnation.com/#JavaScript#NodeJS#VueJS
Mongoose's new `sanitizeFilter` option comes with a new `trusted()` function.
`sanitizeFilter` removes all query selectors. But you can wrap a query selector in `trusted()` to let the query selector through 👍
mongoosejs.com/docs/migratin…#NodeJS#MongoDB#JavaScript
One of our favorite improvements in Mongoose 6 is the `sanitizeFilter` option.
Turn on `sanitizeFilter` and Mongoose will automatically protect you against query selector injections!
mongoosejs.com/docs/migratin…#NodeJS#MongoDB#JavaScript
In Mongoose 6, we removed the `strictQuery` option. The `strict` option now applies to query filters, which means Mongoose will remove fields from the query filter that are not in the schema.
Learn more: mongoosejs.com/docs/migratin…#NodeJS#MongoDB#JavaScript
Connections are no longer thenable in Mongoose 6.
That means, if you use `await mongoose.createConnection()` in Mongoose 5, you need to add an `asPromise()` call in Mongoose 6.
More info: mongoosejs.com/docs/migratin…#NodeJS#MongoDB#JavaScript