Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add null to select override return type for findOne #14545

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 4 additions & 3 deletions types/query.d.ts
Expand Up @@ -701,9 +701,10 @@
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