2022-12-23 05:50:14 +00:00
|
|
|
package validator
|
|
|
|
|
|
|
|
import (
|
2023-03-17 18:52:56 +00:00
|
|
|
"github.com/prysmaticlabs/prysm/v4/beacon-chain/state"
|
|
|
|
"github.com/prysmaticlabs/prysm/v4/consensus-types/primitives"
|
|
|
|
ethpb "github.com/prysmaticlabs/prysm/v4/proto/prysm/v1alpha1"
|
2022-12-23 05:50:14 +00:00
|
|
|
)
|
|
|
|
|
2023-01-26 14:40:12 +00:00
|
|
|
func (vs *Server) getExits(head state.BeaconState, slot primitives.Slot) []*ethpb.SignedVoluntaryExit {
|
2023-03-01 16:44:00 +00:00
|
|
|
exits, err := vs.ExitPool.ExitsForInclusion(head, slot)
|
|
|
|
if err != nil {
|
|
|
|
log.WithError(err).Error("Could not get exits")
|
|
|
|
return []*ethpb.SignedVoluntaryExit{}
|
2022-12-23 05:50:14 +00:00
|
|
|
}
|
2023-03-01 16:44:00 +00:00
|
|
|
return exits
|
2022-12-23 05:50:14 +00:00
|
|
|
}
|