good morning!!!!

Skip to content
Snippets Groups Projects
Commit 1382e8d8 authored by Jeffrey Wilcke's avatar Jeffrey Wilcke
Browse files

Delete current chain for reset

parent e2e3fa3d
No related branches found
No related tags found
No related merge requests found
......@@ -198,6 +198,10 @@ func (bc *ChainManager) Reset() {
bc.mu.Lock()
defer bc.mu.Unlock()
for block := bc.currentBlock; block != nil; block = bc.GetBlock(block.Header().ParentHash) {
ethutil.Config.Db.Delete(block.Hash())
}
// Prepare the genesis block
bc.write(bc.genesisBlock)
bc.insert(bc.genesisBlock)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment