Skip to content

Commit

Permalink
core/txpool: only removeAuthorities for SetCodeTxType txs
Browse files Browse the repository at this point in the history
  • Loading branch information
buddh0 committed Feb 25, 2025
1 parent 7d8aca9 commit 8692589
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion core/txpool/legacypool/legacypool.go
Original file line number Diff line number Diff line change
Expand Up @@ -1765,12 +1765,14 @@ func (t *lookup) Remove(hash common.Hash) {
t.lock.Lock()
defer t.lock.Unlock()

t.removeAuthorities(hash)
tx, ok := t.txs[hash]
if !ok {
log.Error("No transaction found to be deleted", "hash", hash)
return
}
if tx.Type() == types.SetCodeTxType {
t.removeAuthorities(hash)
}
t.slots -= numSlots(tx)
slotsGauge.Update(int64(t.slots))

Expand Down

0 comments on commit 8692589

Please sign in to comment.