MCPcopy Create free account
hub / github.com/GetStream/stream-cli / printJSONObject

Function printJSONObject

pkg/utils/printer.go:29–38  ·  view source on GitHub ↗
(cmd *cobra.Command, object interface{})

Source from the content-addressed store, hash-verified

27}
28
29func printJSONObject(cmd *cobra.Command, object interface{}) error {
30 b, err := json.MarshalIndent(object, "", " ")
31 if err != nil {
32 return err
33 }
34
35 cmd.Println(string(b))
36
37 return nil
38}
39
40func printUIObject(cmd *cobra.Command, object interface{}) error {
41 var asMap map[string]interface{}

Callers 1

PrintObjectFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected