Update reader.go

This commit is contained in:
crStiv 2025-02-07 17:21:54 +01:00 committed by GitHub
parent d11e9c0b51
commit 1bfb8f0a66
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -114,7 +114,7 @@ func (r *reader) Account(hash common.Hash) (*types.SlimAccount, error) {
} }
account := new(types.SlimAccount) account := new(types.SlimAccount)
if err := rlp.DecodeBytes(blob, account); err != nil { if err := rlp.DecodeBytes(blob, account); err != nil {
panic(err) return nil, fmt.Errorf("failed to decode account: %w", err)
} }
return account, nil return account, nil
} }