core/rawdb: add slow path for getting legacy logs (#23879)

* eth/tracers: add slow path for getting legacy logs

* core/rawdb: fix test
This commit is contained in:
Sina Mahmoodi
2021-11-11 15:04:06 +01:00
committed by GitHub
parent f32feeb260
commit c57df9ca28
3 changed files with 24 additions and 4 deletions

View File

@ -187,7 +187,7 @@ func (b *EthAPIBackend) GetLogs(ctx context.Context, hash common.Hash) ([][]*typ
if number == nil {
return nil, errors.New("failed to get block number from hash")
}
logs := rawdb.ReadLogs(db, hash, *number)
logs := rawdb.ReadLogs(db, hash, *number, b.eth.blockchain.Config())
if logs == nil {
return nil, errors.New("failed to get logs for block")
}