This documents _id.
Empty object that you can use for storing properties on the document. This is handy for passing data to middleware without conflicting with Mongoose internals.
A string containing the current operation that Mongoose is executing
on this document. Can be null, 'save', 'validate', or 'remove'.
Set this property to add additional query filters when Mongoose saves this document and isNew is false.
OptionalbaseIf this is a discriminator model, baseModelName is the name of the base model.
Collection the model uses.
Connection the model uses.
The user email.
OptionalerrorsReturns the current validation errors.
OptionalidThe string version of this documents _id.
Boolean flag specifying if the document is new.
The user password.
The document's schema.
Returns true if the given path is nullish or only contains empty objects. Useful for determining whether this subdoc will get stripped out by the minimize option.
Alias for set(), used internally to avoid conflicts
Optionaloptions: DocumentSetOptionsOptionaloptions: DocumentSetOptionsMarks a path as invalid, causing validation to fail.
Optionalvalue: anyOptionalkind: stringOptionalvalue: anyOptionalkind: stringReturns true if path was directly set and modified, else false.
Returns true if any of the given paths are modified, else false. If no arguments, returns true if any path
in this document is modified.
Optionalpath: string | string[]Optionaloptions: null | { Populates document references.
Optionalselect: string | AnyObjectOptionalmodel: Model<any, {}, {}, {}, any, any>Optionalmatch: AnyObjectOptionaloptions: PopulateOptionsSends a replaceOne command with this document _id as the query selector.
Optionalreplacement: AnyObjectOptionaloptions: null | QueryOptions<unknown>Saves this document by inserting a new document into the database if document.isNew is true, or sends an updateOne operation with just the modified paths if isNew is false.
Optionaloptions: SaveOptionsSets the value of a path, or many paths.
Optionaloptions: DocumentSetOptionsOptionaloptions: DocumentSetOptionsOptionaloptions: DocumentSetOptionsThe return value of this method is used in calls to JSON.stringify(doc).
Optionaloptions: ToObjectOptions<Document<unknown, {}, unknown> & { Optionaloptions: ToObjectOptions<Document<unknown, {}, unknown> & { Converts this document into a plain-old JavaScript object (POJO).
Optionaloptions: ToObjectOptions<Document<unknown, {}, unknown> & { Optionaloptions: ToObjectOptions<Document<unknown, {}, unknown> & { Sends an updateOne command with this document _id as the query selector.
Optionalupdate: UpdateWithAggregationPipeline | UpdateQuery<IUser>Optionaloptions: null | QueryOptions<unknown>Executes registered validation rules for this document.
OptionalpathsToValidate: PathsToValidateOptionaloptions: AnyObjectOptionalpathsExecutes registered validation rules (skipping asynchronous validators) for this document.
OptionalpathsOptionalpathsToValidate: PathsToValidateOptionaloptions: AnyObject
User interface