From 939926c92304a306299c2adfd8aed4cff090c3cb Mon Sep 17 00:00:00 2001 From: Jeremy Letang Date: Thu, 15 Aug 2024 15:34:48 +0100 Subject: [PATCH] chore: linter Signed-off-by: Jeremy Letang --- core/validators/signatures.go | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/core/validators/signatures.go b/core/validators/signatures.go index 7f0ab56f75..9414990673 100644 --- a/core/validators/signatures.go +++ b/core/validators/signatures.go @@ -132,12 +132,12 @@ type NodeIDAddress struct { } // isBridge returns whether the given chainID corresponds to one of the bridges, and returns if it is the Ethereum bridge. -func (s *ERC20Signatures) isBridge(chainID string) (isBridge bool, isEthereum bool) { +func (s *ERC20Signatures) isBridge(chainID string) (isBridge bool) { switch chainID { case s.primaryMultisig.ChainID(): - isBridge, isEthereum = true, true + isBridge = true case s.secondaryMultisig.ChainID(): - isBridge, isEthereum = true, false + isBridge = true } return } @@ -179,7 +179,7 @@ func (s *ERC20Signatures) offerValidatorAddedSignatures(resID string) []byte { s.log.Panic("expected added signature but got removed signature instead", logging.String("ethereumAddress", sig.EthAddress)) } - isBridge, _ := s.isBridge(sig.chainID) + isBridge := s.isBridge(sig.chainID) if !isBridge { s.log.Panic("unexpected bridge chainID", logging.String("chain-id", sig.chainID)) } @@ -207,7 +207,7 @@ func (s *ERC20Signatures) offerValidatorRemovedSignatures(resID string) []byte { s.log.Panic("expected removed signature but got added signature instead", logging.String("ethereumAddress", sig.EthAddress)) } - isBridge, _ := s.isBridge(sig.chainID) + isBridge := s.isBridge(sig.chainID) if !isBridge { s.log.Panic("unexpected bridge chainID", logging.String("chain-id", sig.chainID)) } @@ -335,7 +335,7 @@ func (s *ERC20Signatures) EmitValidatorAddedSignatures(ctx context.Context, subm return ErrNoPendingSignaturesForNodeID } - isBridge, _ := s.isBridge(chainID) + isBridge := s.isBridge(chainID) if !isBridge { return ErrUnknownChainID } @@ -398,7 +398,7 @@ func (s *ERC20Signatures) EmitValidatorRemovedSignatures(ctx context.Context, su return ErrNoPendingSignaturesForNodeID } - isBridge, _ := s.isBridge(chainID) + isBridge := s.isBridge(chainID) if !isBridge { return ErrUnknownChainID }