mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-06-14 19:01:36 +00:00
core/txpool/legacypool: remove redundant nil check in Get
This commit is contained in:
parent
5d0e18f775
commit
4c8b7f1feb
1 changed files with 1 additions and 5 deletions
|
|
@ -998,11 +998,7 @@ func (pool *LegacyPool) Status(hash common.Hash) txpool.TxStatus {
|
||||||
|
|
||||||
// Get returns a transaction if it is contained in the pool and nil otherwise.
|
// Get returns a transaction if it is contained in the pool and nil otherwise.
|
||||||
func (pool *LegacyPool) Get(hash common.Hash) *types.Transaction {
|
func (pool *LegacyPool) Get(hash common.Hash) *types.Transaction {
|
||||||
tx := pool.get(hash)
|
return pool.get(hash)
|
||||||
if tx == nil {
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
return tx
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// get returns a transaction if it is contained in the pool and nil otherwise.
|
// get returns a transaction if it is contained in the pool and nil otherwise.
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue