Skip to content

Commit

Permalink
fix: return type of findByID and disableErrors
Browse files Browse the repository at this point in the history
  • Loading branch information
r1tsuu committed Oct 30, 2024
1 parent d89db00 commit 45279bc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/payload/src/types/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -163,9 +163,9 @@ export type SelectMode = 'exclude' | 'include'

export type SelectType = SelectExcludeType | SelectIncludeType

export type ApplyDisableErrors<T, DisableErrors extends boolean> = DisableErrors extends true
? null | T
: T
export type ApplyDisableErrors<T, DisableErrors = false> = false extends DisableErrors
? T
: null | T

export type TransformDataWithSelect<
Data extends Record<string, any>,
Expand Down

0 comments on commit 45279bc

Please sign in to comment.