Skip to content

Releases: Automattic/mongoose

9.2.1

11 Feb 16:46

Choose a tag to compare

9.2.1 / 2026-02-11

  • types(query): allow assigning QueryFilter<DocType> to QueryFilter<any> #16020
  • types: duplicate identifier 'UUIDToJSON' in mongoosejs 9.2.0 #16023
  • types: preserve subdocument toObject() field types when using virtuals + versionKey options #16021 #15965 AbdelrahmanHafez
  • docs(mongoose): add missing options to mongoose.set() docs #16019

9.2.0

09 Feb 21:58

Choose a tag to compare

9.2.0 / 2026-02-09

  • feat: add option to skip middleware #15883 #8768 AbdelrahmanHafez
  • feat(model): delay "Duplicate schema index" warning until createIndexes runs to include model name in the warning #15979
  • feat(model): add strict option to Model.hydrate(...) #15940 #15977
  • feat(document): add flattenUUIDs option to toObject() and toJSON() #15864 #15021 AbdelrahmanHafez
  • fix(schema): treat undefined as not provided for strict, strictQuery and id options #16004 AbdelrahmanHafez
  • types(inferrawdoctype): avoid adding _id to nested paths and handle _id: false in options + schema definition #15989
  • types: fix toObject() type inference with timestamps + virtuals #15975 AbdelrahmanHafez
  • types(models): remove dead MapReduce and GeoSearch types #15984
  • test(types): remove tsd in favor of tsc + test utilities #15951 #15696

8.23.0

09 Feb 20:52

Choose a tag to compare

8.23.0 / 2026-02-09

  • feat(document): add flattenUUIDs option to toObject() and toJSON() (backport #15021 to 8.x)

9.1.6

04 Feb 20:31

Choose a tag to compare

9.1.6 / 2026-02-04

  • fix: handle other top-level query operators in sanitizeFilter
  • fix(types): fix toObject() type inference with timestamps + virtuals #15975 #15965 AbdelrahmanHafez
  • fix(populate): defer subpopulate until after match functions to avoid comparing populated subdocs #15981 mongodb-js/mongoose-autopopulate#112
  • fix(DocumentArray): correctly clone subdocument when updating document array #15978 #15973
  • fix(documentArray): fix change tracking for documentArrays in nested maps #15983 #15970 AbdelrahmanHafez
  • docs: clarify that you need to explicitly create timeseries collection before inserting document #15990 #15986

8.22.1

04 Feb 19:45

Choose a tag to compare

8.22.1 / 2025-02-04

  • fix: handle other top-level query operators in sanitizeFilter
  • fix(document): when cloning a doc with subdocs, make sure the subdocs parent is the cloned doc #15904 #15901
  • types(models): support Mongoose query casting in AnyBulkWriteOperation filter property #15910
  • types: add toBSON() to documents #15927

6.13.9

04 Feb 18:57

Choose a tag to compare

6.13.9 / 2026-02-04

  • fix: handle other top-level query operators in sanitizeFilter
  • types(aggregate): add $firstN, $lastN, $bottom, $bottomN, $minN and $maxN operators #15303 #15299
  • docs(compatibility): add note that Mongoose ^6.5 works with MongoDB server 7.x #15427

8.22.0

27 Jan 20:30

Choose a tag to compare

8.22.0 / 2026-01-27

  • feat(model): allow passing strict option to hydrate() #15944 #15940

8.21.1

23 Jan 16:36

Choose a tag to compare

  • fix(clone): fix parent doc for map subdocuments and array subdocuments #15958 AbdelrahmanHafez
  • fix(document): when cloning a doc with subdocs, make sure the subdocs parent is the cloned doc #15904 #15901
  • fix: respect currentTime schema option in bulkWrite updates #15976 sderrow
  • types(models): support Mongoose query casting in AnyBulkWriteOperation filter property #15910
  • types: add toBSON() to documents #15927

9.1.5

20 Jan 16:20

Choose a tag to compare

9.1.5 / 2026-01-20

9.1.4

16 Jan 02:50

Choose a tag to compare

9.1.4 / 2026-01-15