MCPcopy
hub / github.com/cloudfoundry/cli / parseJSON

Function parseJSON

cf/util/json/json_parser.go:75–83  ·  view source on GitHub ↗
(bytes []byte)

Source from the content-addressed store, hash-verified

73}
74
75func parseJSON(bytes []byte) (map[string]interface{}, error) {
76 stringMap := map[string]interface{}{}
77 err := json.Unmarshal(bytes, &stringMap)
78 if err != nil {
79 return nil, fmt.Errorf("Incorrect json format: %s", err.Error())
80 }
81
82 return stringMap, nil
83}

Callers 1

Calls 1

ErrorMethod · 0.65

Tested by

no test coverage detected