core/tracing: fix selfdestruct 6780 balance change emit (#32526)

Noticed in #32376
This commit is contained in:
Sina M 2025-09-02 12:44:09 +02:00 committed by GitHub
parent c36f7bec7f
commit 6f08b3a725
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -242,7 +242,7 @@ func (s *hookedStateDB) SelfDestruct6780(address common.Address) (uint256.Int, b
prev, changed := s.inner.SelfDestruct6780(address)
if s.hooks.OnBalanceChange != nil && changed && !prev.IsZero() {
if s.hooks.OnBalanceChange != nil && !prev.IsZero() {
s.hooks.OnBalanceChange(address, prev.ToBig(), new(big.Int), tracing.BalanceDecreaseSelfdestruct)
}