Re: return type of chaincode functions using EvaluateTransaction

Nikos Karamolegkos

based on this I have to
func (s *smartContract) GetAirQNomVals(ctx contractapi.TransactionContextInterface) (string, error) {
resultsIterator, err := ctx.GetStub().GetState("NominalValuesState")

if err != nil {
return "", fmt.Errorf("failed to read from world state. %s", err.Error())

if resultsIterator == nil {
return "", fmt.Errorf("%s does not exist", "NominalValuesState")

return string(resultsIterator), nil

Join to automatically receive all group messages.