Skip to content
This repository has been archived by the owner on Jan 3, 2024. It is now read-only.

fix(deps): update dependency mongoose to v6 #9

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

renovate[bot]
Copy link

@renovate renovate bot commented Sep 28, 2021

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
mongoose (source) ^5.11.18 -> ^6.0.0 age adoption passing confidence

Release Notes

Automattic/mongoose

v6.7.2

Compare Source

v6.7.1

Compare Source

==================

v6.7.0

Compare Source

==================

  • feat: upgrade to mongodb driver 4.11.0 #​12446
  • feat: add UUID Schema Type (BSON Buffer SubType 4) #​12268 #​3208 hasezoey
  • feat(aggregation): add $fill pipeline stage #​12545 raphael-papazikas
  • feat(types+schema): allow defining schema paths using mongoose.Types.* to work around TS type inference issues #​12352
  • feat(schema): add alias() method that makes it easier to define multiple aliases for a given path #​12368
  • feat(model): add mergeHooks option to Model.discriminator() to avoid duplicate hooks #​12542
  • feat(document): add $timestamps() method to set timestamps for save(), bulkSave(), and insertMany() #​12540

v6.6.7

Compare Source

==================

v6.6.6

Compare Source

==================

v6.6.5

Compare Source

==================

  • fix(document): set defaults on subdocuments underneath init-ed single nested subdocument #​12523 #​12515
  • fix: make Jest fake timers check more robust to other libs that overwrite time functions #​12527 #​12514
  • fix(types): indicate that Schema.prototype.discriminator() returns this #​12522 #​12457
  • fix(types): add "estimatedDocumentCount" and "countDocuments" as possible hooks #​12519 #​12516
  • docs(models): add section on MongoDB Views #​12526 #​5694
  • docs(subdocs): clarify that populated docs are not subdocs #​12521 #​12398
  • docs(change-streams): remove unnecessary obsolete comment about needing to use mongodb driver change streams #​12444

v6.6.4

Compare Source

==================

  • fix(model): avoid saving applied defaults if path is deselected #​12506 #​12414
  • fix(types): correct DocType for auto typed query helpers #​12342
  • fix(types): avoid "excessively deep" type instantiation error when using bulkWrite() with type that extends from document #​12277
  • fix(types): avoid relying on typeof this, which isn't supported in TypeScript < 4.4 #​12375
  • docs(schema): correct example for Schema.prototype.discriminator() #​12493
  • docs(typescript): clean up query helpers examples #​12342
  • chore: use mongodb-memory-server for testing #​12262 hasezoey

v6.6.3

Compare Source

v6.6.2

Compare Source

==================

  • fix(model): avoid deleting shared schema methods in fix for #​12254 #​12423
  • fix(document): set $inc default value in case field has not been specified on the document #​12435 lpizzinidev
  • fix(query): handle select: false on map paths in query results #​12467 lpizzinidev
  • fix(types): add HydratedDocumentFromSchema to make it easier to pull inferred hydrated doc type #​12464 #​12319
  • fix(types): add sanitizeFilter to types #​12465 zrosenbauer
  • fix(types): infer number enum types from schema if using enum: [0, 1] as const #​12463 #​12242
  • docs(validation): add section on global schematype validation, clean up other issues #​12430
  • docs: add clarification about overwrite flag in model.js #​12447 Tzvika-m
  • docs: change to consistent "Example:" for jsdoc comments #​12432 hasezoey

v6.6.1

Compare Source

==================

  • fix: correctly apply defaults after subdoc init #​12328
  • fix(array): avoid using default _id when using pull() #​12294
  • fix: allow null values inside $expr objects #​12429 MartinDrost
  • fix(query): use correct Query constructor when cloning query #​12418
  • docs(website): remove setting "latest38x" which is not used anywhere #​12396 hasezoey

v6.6.0

Compare Source

==================

v6.5.5

Compare Source

==================

  • fix(setDefaultsOnInsert): avoid applying defaults on insert if nested property set #​12279
  • fix(model): make applyHooks() and applyMethods() handle case where custom method is set to Mongoose implementation #​12254
  • fix(types): add string "ascending" and "descending" index-directions #​10269
  • docs: upgrade dox to 1.0.0 #​12403 hasezoey
  • docs: update old mongodb nodejs driver documentation urls #​12387 hasezoey
  • docs: update JSDOC ... (spread) definition #​12388 hasezoey
  • refactor(model): allow optionally passing indexes to createIndexes and cleanIndexes #​12280 AbdelrahmanHafez

v6.5.4

Compare Source

==================

  • fix(document): allow calling $assertPopulated() with values to better support manual population #​12233
  • fix(connection+mongoose): better handling for calling model() with 1 argument #​12359
  • fix(model): allow defining discriminator virtuals and methods using schema options #​12326
  • fix(types): fix MongooseQueryMiddleware missing "findOneAndReplace" and "replaceOne" #​12330 #​12329 Jule- lpizzinidev
  • fix(types): fix replaceOne return type #​12351 lpizzinidev
  • fix(types): use this for return type from $assertPopulated() #​12234
  • docs: highlight how to connect using auth in README #​12354 AntonyOnScript
  • docs: improve jsdoc comments for private methods #​12337 hasezoey
  • docs: fix minor typo in compatibility table header #​12355 skyme5

v6.5.3

Compare Source

==================

v6.5.2

Compare Source

==================

  • fix(aggregate): avoid throwing error when disconnecting with change stream open #​12201 ramos-ph
  • fix(query): overwrite top-level key if using Query.prototype.set() to set to undefined #​12155
  • fix(query): shallow clone options before modifying #​12176
  • fix(types): auto schema type inference on Connection.prototype.model() #​12240 hasezoey
  • fix(types): better typescript support for schema plugins #​12139 emiljanitzek
  • fix(types): make bulkWrite() type param optional #​12221 #​12212
  • docs: misc cleanup #​12199 hasezoey
  • docs: highlight current top-most visible header in navbar #​12222 hasezoey
  • docs(populate): improve examples for Document.prototype.populate() #​12111
  • docs(middleware): clarify document vs model in middleware docs #​12113

v6.5.1

Compare Source

==================

  • fix(timestamps): set timestamps on child schema when child schema has timestamps: true but parent schema does not #​12119
  • fix(schema+timestamps): handle insertMany() with timestamps and discriminators #​12150
  • fix(model+query): handle populate with lean transform that deletes _id #​12143
  • fix(types): allow $pull with _id #​12142
  • fix(types): add schema plugin option inference #​12196 hasezoey
  • fix(types): pass type to mongodb bulk write operation #​12167 emiljanitzek
  • fix(types): map correct generics from model to schema #​12125 emiljanitzek
  • fix(types): avoid baffling circular reference when using PopulatedDoc with a bidirectional reference #​12136
  • fix(types): allow using path with $count #​12149
  • docs(compatibility): change to use a table #​12200 hasezoey
  • docs(api_split.pug): add "code" to sidebar entries #​12153 hasezoey
  • docs: add "code" to Headers (and index list) #​12152 hasezoey

v6.5.0

Compare Source

==================

  • perf(document): avoid creating unnecessary empty objects when creating a state machine #​11988
  • feat: upgrade mongodb driver -> 4.8.1 #​12103 AbdelrahmanHafez
  • feat(model): allow passing timestamps option to Model.bulkSave(...) #​12082 AbdelrahmanHafez
  • feat(model): add castObject() function that casts a POJO to the model's schema #​11945
  • feat(document): add $inc() helper that increments numeric paths #​12115
  • feat(schema): add schema level lean option IslandRhythms
  • feat(schema): add global id option to disable id on schemas #​12067 IslandRhythms
  • fix(connection): re-run Model.init() if re-connecting after explicitly closing a connection #​12130
  • feat(model): add applyDefaults() helper that allows applying defaults to document or POJO #​11945
  • feat(model): allow calling hydrate() with { setters: true } #​11653
  • feat(model): add hydrate option to Model.watch() to automatically hydrate fullDocument #​12121
  • feat(types): add support for automatically typed virtuals in schemas #​11908 mohammad0-0ahmad

v6.4.7

Compare Source

==================

v6.4.6

Compare Source

==================

  • fix(schema): disallow setting proto when creating schema with dotted properties #​12085
  • fix(document): avoid mutating original object passed to $set() when applying defaults to nested properties #​12102
  • fix(query): apply lean transform option to top-level document #​12093
  • docs(migrating_to_6): correct example for isObjectIdOrHexString() #​12123 LokeshKanumoori

v6.4.5

Compare Source

==================

v6.4.4

Compare Source

==================

v6.4.3

Compare Source

==================

  • fix(document): handle validating deeply nested subdocuments underneath nested paths with required: false #​12021
  • fix(types): infer schematype type from schema paths when calling SchemaType.path() #​11987
  • fix(types): add $top and $topN aggregation operators #​12053
  • fix(types): clean up a couple of issues with $add and $ifNull #​12017
  • fix(types): allow $cond with $in #​12028
  • docs: add path level descending index example in docs #​12023 MitchellCash
  • docs: add Buffer, Decimal128, Map to docs #​11971

v6.4.2

Compare Source

==================

  • fix: keep autoIndex & autoCreate as true by default if read preference is primaryPreferred #​11976
  • fix(types): improve inferred Schema Type to handle nested paths and ObjectIds #​12007 iammola
  • fix(types): avoid inferring doc type from param to create() #​12001
  • fix(types): make populate Paths generic consistently overwrite doc interface #​11955
  • fix(types): allow null at ne expression second parameter #​11996 jyeros
  • fix(types): change index "weights" to be more explicit #​11997 hasezoey

v6.4.1

Compare Source

==================

  • fix(schema): allow 0 for numbers if required and ref both set #​11912
  • fix(query): skip applying default projections over slice projections #​11940
  • fix(types): handle arrays in ApplyBasicQueryCasting correctly #​11964
  • fix(types): fix $match typings #​11969 andreialecu
  • fix(types): avoid adding non-existent properties from model constructor for typegoose #​11960
  • fix(types): make Mongoose UpdateQuery compatible with MongoDB UpdateFilter #​11911
  • fix(types): simplify MergeType constraints #​11978
  • fix(types): correct references to Buffer for @​types/node >= 16.0.0 < 16.6.0 #​11963
  • fix(types): re-add the possibility to pass undefined for projection in Model.find #​11965 ghost91-
  • fix(types): fix typo for indexes #​11953 AbdelrahmanHafez
  • fix(document+types): document merge option #​11913
  • docs: update schematypes.md #​11981 korzio
  • docs: update validation.md #​11982 korzio

v6.4.0

Compare Source

==================

v6.3.9

Compare Source

==================

  • fix(document): handle nested paths underneath subdocuments when getting all subdocuments for pre save hooks #​11917
  • fix(types): correct typing in post aggregate hooks #​11924 GCastilho
  • docs: remove connect-option reconnectTries and reconnectInterval #​11930 Uzlopak

v6.3.8

Compare Source

==================

  • fix: revert 670b445 perf optimizations that caused some test failures #​11541

v6.3.7

Compare Source

==================

  • fix(schema+document): allow disabling _id on subdocuments by default #​11541
  • fix(update): respect global strictQuery option when casting array filters #​11836
  • perf(document): avoid unnecessarily creating new options object on every $set #​11541
  • fix: toJSON with undefined path #​11922 kerryChen95
  • fix: add refPath to SchemaTypeOptions class #​11862
  • fix(types): handle boolean default functions #​11828
  • docs(populate): make path names in refPath section consistent #​11724

v6.3.6

Compare Source

==================

  • fix(update): apply timestamps to nested subdocs within $push and $addToSet #​11775
  • fix(document): use shallow clone instead of deep clone for toObject() options #​11776
  • fix: avoid checking for ObjectId with instanceof #​11891 noseworthy
  • fix(types): Allow sorting by text score #​11893
  • fix(types): allow schematype get() functions to return undefined #​11561
  • fix(types): add Schema.discriminator #​11855 Uzlopak
  • fix(types): discriminator generic type not being passed to schema #​11898 GCastilho

v6.3.5

Compare Source

==================

  • fix(document): avoid infinite recursion when calling toObject() on self-referencing document #​11756
  • fix(document): avoid manually populating documents that are manually populated in another doc with different unpopulatedValue #​11442
  • fix(document): fix ObjectId conversion for external schemas #​11841 coyotte508
  • fix: fix codeql warnings #​11817 Uzlopak
  • fix(types): allow passing TVirtuals to Schema class #​11543
  • fix(types): Type of Connection.transaction() #​11825 dwrss
  • docs(typescript): add coverage for TypeScript query helpers #​11709
  • docs: fix documention of error handling #​11844 Uzlopak
  • docs: typings mongoose.Error should reference to MongooseError #​11850 Uzlopak
  • chore: improve issue templates #​11794 Uzlopak
  • chore: use ts-benchmark instead of internal TS benchmarking #​11798 mohammad0-0ahmad

v6.3.4

Compare Source

==================

  • fix(schema): disallow using schemas with schema-level projection with map subdocuments #​11698
  • fix(document): avoid setting nested paths to null when they're undefined #​11723
  • fix: allow using comment with findOneAndUpdate(), count(), distinct() and hint with findOneAndUpdate() #​11793
  • fix(document): clean modified subpaths when setting nested path to null after modifying subpaths #​11764
  • fix(types): allow calling deleteModel() with RegExp in TypeScript #​11812
  • docs(typescript): add section on PopulatedDoc to TypeScript populate docs #​11685

v6.3.3

Compare Source

==================

  • perf: avoid leaking memory when using populate() with QueryCursor because of reusing populate options with _docs #​11641
  • fix(types): add _id back for LeanDocument #​11769 #​11761 taxilian
  • fix(model): add skipValidation option for bulkWrite() to allow skipping validation for insertOne and replaceOne #​11663
  • fix(document): correctly $__reset() subdocuments that are under nested paths #​11672
  • fix(query): handle casting BSONRegExp instances as RegExps in queries #​11597
  • fix: correctly cast $not in $expr #​11689
  • perf: optimize size of browser bundle, use buffer v.5.7.1 package to match buffer package of mongodb in browser bundle #​11765 Uzlopak
  • docs: Query.populate docs do not include using an array of strings for the path param #​11768 #​11641 AbdelrahmanHafez
  • chore: add GitHub workflow to close stale "can't reproduce", "help", "needs clarification" issues #​11753 Uzlopak
  • chore: remove Makefile dependency for compiling docs #​11751 Uzlopak

v6.3.2

Compare Source

==================

  • perf: avoid registering event listeners on subdocuments to reduce memory usage #​11541
  • fix(setDefaultsOnInsert): set default if sibling of nested path is $set #​11668
  • perf(document): remove unnecessary workaround for ignoring subpaths of arrays #​11541
  • fix(types): various fixes and improvements for types #​11650 taxilian
  • fix(types): make mongoose typings work without esmModuleInterop true #​11695 Uzlopak
  • fix(types): support populate(path, fields, model) syntax #​11649 #​11598 mohammad0-0ahmad
  • fix(types): correct SchemaTypeOptions.get function signature #​11561
  • fix: fix browser build for Webpack 5 #​11717
  • docs: improve readme #​11705 mahendrap1512

v6.3.1

Compare Source

==================

  • perf: improve perf of key order #​11639 Uzlopak
  • fix(timestamps): set createdAt when creating new single nested subdocuments #​11603
  • fix: improve CastError message when throwing StrictModeError #​11506
  • fix: upgrade bson to match mongodb@4.5 #​11676
  • fix(populate): avoid populating single nested subdocs underneath arrays if there's no ref #​11538
  • fix: handle { capped: number } in schema definition with createCollection() #​11539
  • fix: call markModified before setting changes in Array and in DocumentArray methods #​11660 josegl
  • fix: only allow using minus path to remove auto-selected discriminatorKey from projection #​11546
  • fix(types): set context on virtual getters/setters by default #​11543
  • fix(types): correct return type for Connection.prototype.transaction #​9919
  • fix(types): allow model as document interface key when using extends Document #​11629
  • docs: improve populate typing #​11690 onichandame
  • docs: add information regarding typings-tests #​11691 Uzlopak
  • docs: fix jsdoc for mongoose.createConnection #​11693 Uzlopak

v6.3.0

Compare Source

==================

v6.2.11

Compare Source

===================

  • fix(document): handle validation with triply nested document arrays #​11564
  • fix(query): skip applying string schema setters on $regex #​11426
  • fix: skip findOneAndReplace() validation if runValidators = false #​11559
  • fix(model): correctly handle schema-level collations in syncIndexes() #​7621
  • fix(types): correct populate query return type with lean #​11560 mohammad0-0ahmad
  • fix(types): allow using { type: Mixed } as schema type definition for any path #​10900
  • docs: fix example on Schema.prototype.post() #​11648 EmilienLeroy
  • docs: fix typo in methods/index.js #​11651 eltociear

v6.2.10

Compare Source

===================

v6.2.9

Compare Source

==================

v6.2.8

Compare Source

==================

  • fix(document): handle casting array of spread docs #​11522
  • fix(document): avoid setting nested properties on top-level document when initing with strict: false #​11526
  • fix(document): correctly handle deeply nested subdocuments when getting paths to validate #​11501
  • fix(types): avoid making TInstanceMethods any by default leading to this = any in middleware [#​11435](https://github.com/Automattic/mongoose/issues/11

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate. View repository job log here.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant