aboutsummaryrefslogtreecommitdiffstats
path: root/eth
diff options
context:
space:
mode:
Diffstat (limited to 'eth')
-rw-r--r--eth/api.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/eth/api.go b/eth/api.go
index 07df0b79e..f38c0a6b6 100644
--- a/eth/api.go
+++ b/eth/api.go
@@ -566,3 +566,9 @@ func (api *PrivateDebugAPI) Preimage(ctx context.Context, hash common.Hash) (hex
db := core.PreimageTable(api.eth.ChainDb())
return db.Get(hash.Bytes())
}
+
+// GetBadBLocks returns a list of the last 'bad blocks' that the client has seen on the network
+// and returns them as a JSON list of block-hashes
+func (api *PrivateDebugAPI) GetBadBlocks(ctx context.Context) ([]core.BadBlockArgs, error) {
+ return api.eth.BlockChain().BadBlocks()
+}