Skip to content
This repository has been archived by the owner on Apr 4, 2022. It is now read-only.

Commit

Permalink
fix type inference
Browse files Browse the repository at this point in the history
  • Loading branch information
Velenir committed Dec 23, 2019
1 parent 90d63f7 commit 5d46f16
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/contracts/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ type EventsExceptAllEvents<T extends Contract> = Omit<T['events'], 'allEvents'>
type AllValues<T extends object> = T[keyof T]

type ChangedEvents<T extends Contract> = {
[E in keyof EventsExceptAllEvents<T>]: ContractEvent<EventArgs<E>>
[E in keyof EventsExceptAllEvents<T>]: ContractEvent<EventArgs<T['events'][E]>>
} & {allEvents: ContractEvent<AllValues<EventsExceptAllEvents<T>>>}

export type ExtendedContract<T extends Contract> = Omit<T, 'events' | 'clone'> & {
Expand Down

0 comments on commit 5d46f16

Please sign in to comment.