Skip to content

Commit 3a17928

Browse files
authored
Add strictPopulate type to PopulateOptions
Added strictPopulate to PopulateOptions, otherwise given option can't be used in TS projects when enforcing types.
1 parent 8b2a662 commit 3a17928

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

types/index.d.ts

+2
Original file line numberDiff line numberDiff line change
@@ -709,6 +709,8 @@ declare module 'mongoose' {
709709
model?: string | Model<any>;
710710
/** optional query options like sort, limit, etc */
711711
options?: any;
712+
/** optional boolean, set to `false` to allow populating paths that aren't in the schema */
713+
strictPopulate?: boolean;
712714
/** deep populate */
713715
populate?: string | PopulateOptions | (string | PopulateOptions)[];
714716
/**

0 commit comments

Comments
 (0)