Skip to content

Commit

Permalink
Fix type issues
Browse files Browse the repository at this point in the history
  • Loading branch information
mtranter committed Mar 2, 2023
1 parent ed34ac3 commit 76f5cdd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lib/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,8 @@ type _NestedPick<
Agg = {}
> = K extends `${infer Key}.${infer Rest}`
? Key extends keyof A
? A[Key] extends object
? { [s in Key]: _NestedPick<A[Key], Rest, Agg> }
? NonNullable<A[Key]> extends Record<string, unknown>
? { [s in Key]: _NestedPick<NonNullable<A[Key]>, Rest, Agg> }
: never
: never
: K extends keyof A & string
Expand Down

0 comments on commit 76f5cdd

Please sign in to comment.