diff --git a/types/lib/model.d.ts b/types/lib/model.d.ts index 72e3a3233b83..da2b3e1bedf6 100644 --- a/types/lib/model.d.ts +++ b/types/lib/model.d.ts @@ -2709,6 +2709,7 @@ export abstract class Model; public previous(key: K): TCreationAttributes[K] | undefined; /** diff --git a/types/test/model.ts b/types/test/model.ts index 0bc5486ca352..d7eaf3b0851a 100644 --- a/types/test/model.ts +++ b/types/test/model.ts @@ -184,3 +184,4 @@ expectTypeOf(modelWithAttributes.previous).parameter(0).toEqualTypeOf(); expectTypeOf(modelWithAttributes.previous).returns.toEqualTypeOf(); expectTypeOf(modelWithAttributes.previous('name')).toEqualTypeOf(); +expectTypeOf(modelWithAttributes.previous()).toEqualTypeOf>();