add difficulty to lightdinfo

This commit is contained in:
Denio
2019-12-02 10:35:38 +01:00
parent a0513c48c3
commit a269cd1e6b
5 changed files with 18 additions and 8 deletions

View File

@@ -168,14 +168,14 @@ func main() {
}
// Get the sapling activation height from the RPC
saplingHeight, blockHeight, chainName, branchID, err := common.GetSaplingInfo(rpcClient)
saplingHeight, blockHeight, chainName, branchID, difficulty, err := common.GetSaplingInfo(rpcClient)
if err != nil {
log.WithFields(logrus.Fields{
"error": err,
}).Warn("Unable to get sapling activation height")
}
log.Info("Got sapling height ", saplingHeight, " chain ", chainName, " branchID ", branchID)
log.Info("Got sapling height ", saplingHeight, " chain ", chainName, " branchID ", branchID," difficulty ", difficulty,)
// Initialize the cache
cache := common.NewBlockCache(opts.cacheSize)