diff --git a/core/chaincode/shim/chaincode.go b/core/chaincode/shim/chaincode.go index b6b0d4e5607..11c10eda8a9 100644 --- a/core/chaincode/shim/chaincode.go +++ b/core/chaincode/shim/chaincode.go @@ -97,6 +97,9 @@ func Start(cc Chaincode) error { } chaincodename := viper.GetString("chaincode.id.name") + if chaincodename == "" { + return fmt.Errorf("Error chaincode id not provided") + } err = chatWithPeer(chaincodename, stream, cc) return err