✨ event emit

This commit is contained in:
Flam3rboy
2021-08-13 13:00:31 +02:00
parent 0a08938d18
commit 644430921a
7 changed files with 139 additions and 93 deletions
+3
View File
@@ -12,6 +12,9 @@ type UpdateAggregationStage =
type EnforceDocument<T, TMethods> = T extends Document ? T : T & Document & TMethods;
declare module "mongoose" {
interface SchemaOptions {
removeResponse?: string[];
}
interface Model<T, TQueryHelpers = {}, TMethods = {}> {
// removed null -> always return document -> throw error if it doesn't exist
findOne(