core/txpool: remove unused function GetSender (#1886)

This commit is contained in:
wit liu 2025-12-23 14:26:34 +08:00 committed by GitHub
parent d78d79add0
commit 13b0e39412
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 0 additions and 26 deletions

View file

@ -405,15 +405,6 @@ func (pool *LendingPool) local() map[common.Address]types.LendingTransactions {
return txs
}
// GetSender get sender from transaction
func (pool *LendingPool) GetSender(tx *types.LendingTransaction) (common.Address, error) {
from, err := types.LendingSender(pool.signer, tx)
if err != nil {
return common.Address{}, ErrInvalidSender
}
return from, nil
}
func (pool *LendingPool) validateNewLending(cloneStateDb *state.StateDB, cloneLendingStateDb *lendingstate.LendingStateDB, tx *types.LendingTransaction) error {
lendingSide := tx.Side()
lendingType := tx.Type()

View file

@ -428,15 +428,6 @@ func (pool *OrderPool) local() map[common.Address]types.OrderTransactions {
return txs
}
// GetSender get sender from transaction
func (pool *OrderPool) GetSender(tx *types.OrderTransaction) (common.Address, error) {
from, err := types.OrderSender(pool.signer, tx)
if err != nil {
return common.Address{}, ErrInvalidSender
}
return from, nil
}
func (pool *OrderPool) validateOrder(tx *types.OrderTransaction) error {
orderSide := tx.Side()
orderType := tx.Type()

View file

@ -607,14 +607,6 @@ func (pool *TxPool) local() map[common.Address]types.Transactions {
return txs
}
func (pool *TxPool) GetSender(tx *types.Transaction) (common.Address, error) {
from, err := types.Sender(pool.signer, tx)
if err != nil {
return common.Address{}, ErrInvalidSender
}
return from, nil
}
// validateTxBasics checks whether a transaction is valid according to the consensus
// rules, but does not check state-dependent validation such as sufficient balance.
// This check is meant as an early check which only needs to be performed once,