prysm-pulse/beacon-chain/rpc/prysm/v1alpha1/validator/proposer_exits.go

17 lines
502 B
Go
Raw Normal View History

package validator
import (
"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"
)
func (vs *Server) getExits(head state.BeaconState, slot primitives.Slot) []*ethpb.SignedVoluntaryExit {
exits, err := vs.ExitPool.ExitsForInclusion(head, slot)
if err != nil {
log.WithError(err).Error("Could not get exits")
return []*ethpb.SignedVoluntaryExit{}
}
return exits
}