diff --git a/types/index.d.ts b/types/index.d.ts index 0ebeac0933..9a60491443 100644 --- a/types/index.d.ts +++ b/types/index.d.ts @@ -623,7 +623,7 @@ declare module 'mongoose' { /** Adds static "class" methods to Models compiled from this schema. */ static(name: K, fn: TStaticMethods[K]): this; - static(obj: { [F in keyof TStaticMethods]: TStaticMethods[F] } & { [name: string]: (this: TModelType, ...args: any[]) => any }): this; + static(obj: { [F in keyof TStaticMethods]?: TStaticMethods[F] } & { [name: string]: (this: TModelType, ...args: any[]) => any }): this; static(name: string, fn: (this: TModelType, ...args: any[]) => any): this; /** Object of currently defined statics on this schema. */