mongoose 6.2.4 → 6.2.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,36 @@
1
+ 6.2.7 / 2022-03-16
2
+ ==================
3
+ * perf(document): avoid running validation on every array element if there's no validators to run #11380
4
+ * fix(cursor): correctly populate in batches when batchSize is set #11509
5
+ * fix(connection): avoid setting MongoClient on useDb() connections until after setting on base connection #11445
6
+ * fix(schema): throw more helpful error when using schema from a different version of Mongoose module #10453
7
+ * fix: add missing timeseries expiration handling #11489 #11229 [Uzlopak](https://github.com/Uzlopak)
8
+ * docs: correct Model.findOneAndReplace docs param naming #11524 [anatolykopyl](https://github.com/anatolykopyl)
9
+
10
+ 6.2.6 / 2022-03-11
11
+ ==================
12
+ * fix(types): correct reference to cursor TypeScript bindings #11513 [SimonHausdorf](https://github.com/SimonHausdorf)
13
+ * fix(types): allow calling Query.prototype.populate() with array of strings #11518
14
+ * fix(types): export and refactor types of PreMiddlewareFunction, PreSaveMiddlewareFunction, PostMiddlewareFunction, ErrorHandlingMiddlewareFunction #11485 [Uzlopak](https://github.com/Uzlopak)
15
+
16
+ 6.2.5 / 2022-03-09
17
+ ==================
18
+ * fix(mongoose): add isObjectIdOrHexString() to better capture the most common use case for `isValidObjectId()` #11419
19
+ * fix(query): prevent modifying discriminator key in updates using operators other than `$set` #11456
20
+ * fix(populate+types): call foreignField functions with doc as 1st param, better typings for `localField` and `foreignField` functions #11321
21
+ * fix(populate): return an array when using populate count on an array localField #11307
22
+ * fix(query): avoid error when using $not with arrays #11467
23
+ * perf: only deep clone validators if necessary #11412 [Uzlopak](https://github.com/Uzlopak)
24
+ * fix(types): rename definition files to lowercase to avoid typescript bug #11469
25
+ * fix(types): aggregate.sort() accepts a string but also `{ field: 'asc'|'ascending'|'desc'|'descending' }` #11479 [simonbrunel](https://github.com/simonbrunel)
26
+ * fix(types): extract and refactor aggregationcursor and querycursor #11488 [Uzlopak](https://github.com/Uzlopak)
27
+ * fix(types): extract and refactor schemaoptions #11484 [Uzlopak](https://github.com/Uzlopak)
28
+ * fix(types): make first param to `Query.prototype.populate()` a string #11475 [minhthinhls](https://github.com/minhthinhls)
29
+ * fix(types): improve type checking for doc arrays in schema definitions #11241
30
+ * docs: fix length comparaison in lean.test.js #11493 [zazapeta](https://github.com/zazapeta)
31
+ * docs(timestamps): fix typo #11481 [saibbyweb](https://github.com/saibbyweb)
32
+ * docs: fix broken link to rawResult #11459 [chhiring90](https://github.com/chhiring90)
33
+
1
34
  6.2.4 / 2022-02-28
2
35
  ==================
3
36
  * fix(query): correctly return full deleteOne(), deleteMany() result #11211