aboutsummaryrefslogtreecommitdiffstats
path: root/les
diff options
context:
space:
mode:
authorPéter Szilágyi <peterke@gmail.com>2018-02-23 17:50:16 +0800
committerGitHub <noreply@github.com>2018-02-23 17:50:16 +0800
commit7f74bdf8dded0e1ac3c01e043c2ed89d78f308cf (patch)
tree066d68abcb5cbe1980b0b770b8d135e06b54225d /les
parenta1984ce727642b1989657b9eb430562d47f89c70 (diff)
parent5cf1d354704cd2cbc5c64c96d4aaabeeec7dd161 (diff)
downloaddexon-7f74bdf8dded0e1ac3c01e043c2ed89d78f308cf.tar
dexon-7f74bdf8dded0e1ac3c01e043c2ed89d78f308cf.tar.gz
dexon-7f74bdf8dded0e1ac3c01e043c2ed89d78f308cf.tar.bz2
dexon-7f74bdf8dded0e1ac3c01e043c2ed89d78f308cf.tar.lz
dexon-7f74bdf8dded0e1ac3c01e043c2ed89d78f308cf.tar.xz
dexon-7f74bdf8dded0e1ac3c01e043c2ed89d78f308cf.tar.zst
dexon-7f74bdf8dded0e1ac3c01e043c2ed89d78f308cf.zip
Merge pull request #16164 from karalabe/les-receipt-fix-optimal
eth, les, light: filter on logs only, derive receipts on demand
Diffstat (limited to 'les')
-rw-r--r--les/api_backend.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/les/api_backend.go b/les/api_backend.go
index 56f617a7d..3fc5c33a4 100644
--- a/les/api_backend.go
+++ b/les/api_backend.go
@@ -87,6 +87,10 @@ func (b *LesApiBackend) GetReceipts(ctx context.Context, blockHash common.Hash)
return light.GetBlockReceipts(ctx, b.eth.odr, blockHash, core.GetBlockNumber(b.eth.chainDb, blockHash))
}
+func (b *LesApiBackend) GetLogs(ctx context.Context, blockHash common.Hash) ([][]*types.Log, error) {
+ return light.GetBlockLogs(ctx, b.eth.odr, blockHash, core.GetBlockNumber(b.eth.chainDb, blockHash))
+}
+
func (b *LesApiBackend) GetTd(blockHash common.Hash) *big.Int {
return b.eth.blockchain.GetTdByHash(blockHash)
}