MCPcopy Create free account
hub / github.com/basecamp/hey-cli / normalizeAny

Function normalizeAny

internal/cmd/sdk.go:231–237  ·  view source on GitHub ↗

normalizeAny converts a typed SDK response to an any suitable for writeOK by JSON round-tripping through json.Number-preserving decoder.

(v any)

Source from the content-addressed store, hash-verified

229// normalizeAny converts a typed SDK response to an any suitable for writeOK
230// by JSON round-tripping through json.Number-preserving decoder.
231func normalizeAny(v any) (any, error) {
232 data, err := json.Marshal(v)
233 if err != nil {
234 return nil, err
235 }
236 return output.NormalizeJSONNumbers(data)
237}

Callers 6

runMethod · 0.85
runMethod · 0.85
runMethod · 0.85
runMethod · 0.85
runMethod · 0.85
runMethod · 0.85

Calls 1

NormalizeJSONNumbersFunction · 0.92

Tested by

no test coverage detected