BaseRunner can only have single share but currently it's stored (and returned) as a map -
|
Share map[phase0.ValidatorIndex]*spectypes.Share |
we probably want to refactor that - BUT only after #2136 is merged (since it touches a lot of the code in the same area)
Since every Runner uses BaseRunner in some manner we might want to adjust runners too if that makes sense.
Note: CommitteeRunner might be an exception, be careful about that!
Update: seems like we need to preserve the map for BaseRunner.Share but rename it Share->Shares (and corresponding inits), make it package private, and maybe get rid of GetShares method
BaseRunnercan only have single share but currently it's stored (and returned) as a map -ssv/protocol/v2/ssv/runner/runner.go
Line 79 in b7d1688
we probably want to refactor that - BUT only after #2136 is merged (since it touches a lot of the code in the same area)
Since every
RunnerusesBaseRunnerin some manner we might want to adjust runners too if that makes sense.Note:
CommitteeRunnermight be an exception, be careful about that!Update: seems like we need to preserve the map for
BaseRunner.Sharebut rename itShare->Shares(and corresponding inits), make it package private, and maybe get rid ofGetSharesmethod