mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-18 19:00:46 +00:00
core/txpool: remove unused function GetSender (#1886)
This commit is contained in:
parent
d78d79add0
commit
13b0e39412
3 changed files with 0 additions and 26 deletions
|
|
@ -405,15 +405,6 @@ func (pool *LendingPool) local() map[common.Address]types.LendingTransactions {
|
||||||
return txs
|
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 {
|
func (pool *LendingPool) validateNewLending(cloneStateDb *state.StateDB, cloneLendingStateDb *lendingstate.LendingStateDB, tx *types.LendingTransaction) error {
|
||||||
lendingSide := tx.Side()
|
lendingSide := tx.Side()
|
||||||
lendingType := tx.Type()
|
lendingType := tx.Type()
|
||||||
|
|
|
||||||
|
|
@ -428,15 +428,6 @@ func (pool *OrderPool) local() map[common.Address]types.OrderTransactions {
|
||||||
return txs
|
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 {
|
func (pool *OrderPool) validateOrder(tx *types.OrderTransaction) error {
|
||||||
orderSide := tx.Side()
|
orderSide := tx.Side()
|
||||||
orderType := tx.Type()
|
orderType := tx.Type()
|
||||||
|
|
|
||||||
|
|
@ -607,14 +607,6 @@ func (pool *TxPool) local() map[common.Address]types.Transactions {
|
||||||
return txs
|
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
|
// validateTxBasics checks whether a transaction is valid according to the consensus
|
||||||
// rules, but does not check state-dependent validation such as sufficient balance.
|
// 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,
|
// This check is meant as an early check which only needs to be performed once,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue