This utilizes a union type for function vs events and should be genericized so the correct object type can be toggled based on the Action type. _Originally posted by @topocount in https://github.com/rabbitholegg/boost-protocol/issues/106#issuecomment-2379911309_