MCPcopy Create free account
hub / github.com/chainreactors/EvilProxy / prettyJSON

Function prettyJSON

cmd/fetch_codex_models/main.go:310–317  ·  view source on GitHub ↗
(raw []byte)

Source from the content-addressed store, hash-verified

308}
309
310func prettyJSON(raw []byte) ([]byte, error) {
311 var buf bytes.Buffer
312 if err := json.Indent(&buf, raw, "", " "); err != nil {
313 return nil, err
314 }
315 buf.WriteByte('\n')
316 return buf.Bytes(), nil
317}
318
319func metaStringValue(m map[string]any, key string) string {
320 if m == nil {

Callers 1

mainFunction · 0.70

Calls 1

BytesMethod · 0.80

Tested by

no test coverage detected