blockchain_go/cli_reindexutxo.go

13 lines
229 B
Go
Raw Normal View History

2017-09-16 22:30:30 -05:00
package main
import "fmt"
func (cli *CLI) reindexUTXO() {
bc := NewBlockchain()
2017-09-16 22:30:30 -05:00
UTXOSet := UTXOSet{bc}
UTXOSet.Reindex()
count := UTXOSet.GetCount()
fmt.Printf("Done! There are %d transactions in the UTXO set.", count)
}