Function calculateRelaySetFromEvent