From 5f909caedff426563b7eec2498bdb8baeeb1bde0 Mon Sep 17 00:00:00 2001 From: terence Date: Sun, 14 Apr 2024 09:38:25 -0700 Subject: [PATCH] Remove unused IsViableForCheckpoint (#13879) --- beacon-chain/blockchain/chain_info.go | 9 --------- 1 file changed, 9 deletions(-) diff --git a/beacon-chain/blockchain/chain_info.go b/beacon-chain/blockchain/chain_info.go index e9c9d6a097..30dfeac964 100644 --- a/beacon-chain/blockchain/chain_info.go +++ b/beacon-chain/blockchain/chain_info.go @@ -11,7 +11,6 @@ import ( "github.com/prysmaticlabs/prysm/v5/beacon-chain/core/helpers" f "github.com/prysmaticlabs/prysm/v5/beacon-chain/forkchoice" doublylinkedtree "github.com/prysmaticlabs/prysm/v5/beacon-chain/forkchoice/doubly-linked-tree" - forkchoicetypes "github.com/prysmaticlabs/prysm/v5/beacon-chain/forkchoice/types" "github.com/prysmaticlabs/prysm/v5/beacon-chain/state" fieldparams "github.com/prysmaticlabs/prysm/v5/config/fieldparams" "github.com/prysmaticlabs/prysm/v5/config/params" @@ -399,14 +398,6 @@ func (s *Service) InForkchoice(root [32]byte) bool { return s.cfg.ForkChoiceStore.HasNode(root) } -// IsViableForCheckpoint returns whether the given checkpoint is a checkpoint in any -// chain known to forkchoice -func (s *Service) IsViableForCheckpoint(cp *forkchoicetypes.Checkpoint) (bool, error) { - s.cfg.ForkChoiceStore.RLock() - defer s.cfg.ForkChoiceStore.RUnlock() - return s.cfg.ForkChoiceStore.IsViableForCheckpoint(cp) -} - // IsOptimisticForRoot takes the root as argument instead of the current head // and returns true if it is optimistic. func (s *Service) IsOptimisticForRoot(ctx context.Context, root [32]byte) (bool, error) {