Last updated 3 years ago
Was this helpful?
Here is out main method which will be starting the chaincode when we deploy it to fabric runtime on peer nodes
main.go func main() { voteContract := new(vote.VoteContract) chaincode, err := contractapi.NewChaincode(voteContract) if err != nil { panic(err) } err = chaincode.Start() if err != nil { panic(err.Error()) } }