Skip to content

Commit

Permalink
Add null to select override return type
Browse files Browse the repository at this point in the history
  • Loading branch information
sderrow committed Apr 28, 2024
1 parent 3072c41 commit f0dc26f
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions types/query.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -701,9 +701,10 @@ declare module 'mongoose' {
ResultType extends HydratedDocument<any>[] ?
HydratedDocument<RawDocTypeOverride>[] :
RawDocTypeOverride[] :
ResultType extends HydratedDocument<any> ?
HydratedDocument<RawDocTypeOverride> :
RawDocTypeOverride
| (ResultType extends HydratedDocument<any>

Check warning on line 704 in types/query.d.ts

View workflow job for this annotation

GitHub Actions / Lint TS-Files

Expected indentation of 10 spaces but found 14
? HydratedDocument<RawDocTypeOverride>

Check warning on line 705 in types/query.d.ts

View workflow job for this annotation

GitHub Actions / Lint TS-Files

Expected indentation of 12 spaces but found 16
: RawDocTypeOverride)

Check warning on line 706 in types/query.d.ts

View workflow job for this annotation

GitHub Actions / Lint TS-Files

Expected indentation of 12 spaces but found 16
| (null extends ResultType ? null : never)

Check warning on line 707 in types/query.d.ts

View workflow job for this annotation

GitHub Actions / Lint TS-Files

Expected indentation of 10 spaces but found 14
>,
DocType,
THelpers,
Expand Down

0 comments on commit f0dc26f

Please sign in to comment.