mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 18:32:23 +00:00
update getblockbynumber to use same type casting as headerbynumber
This commit is contained in:
parent
2e8ecf3dc0
commit
de06789c9a
1 changed files with 1 additions and 1 deletions
|
|
@ -191,7 +191,7 @@ func (b *SimulatedBackend) BlockByNumber(ctx context.Context, number *big.Int) (
|
|||
if number == nil {
|
||||
return b.blockchain.CurrentBlock(), nil
|
||||
}
|
||||
block := b.blockchain.GetBlockByNumber(number.Uint64())
|
||||
block := b.blockchain.GetBlockByNumber(uint64(number.Int64()))
|
||||
if block == nil {
|
||||
return nil, errBlockDoesNotExist
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue