code: func newBestState(node *blockNode, blockSize, blockWeight, numTxns,
  	totalTxns uint64, medianTime time.Time) *BestState {
  
  	return &BestState{
  		Hash:        node.hash,
  		Height:      node.height,
  		Bits:        node.bits,
  		BlockSize:   blockSize,
  		BlockWeight: blockWeight,
  		NumTxns:     numTxns,
  		TotalTxns:   totalTxns,
  		MedianTime:  medianTime,
  	}
  }
docs: // newBestState returns a new best stats instance for the given parameters.