MCPcopy Create free account
hub / github.com/authorizerdev/authorizer / isJSONNull

Function isJSONNull

internal/mcp/server.go:228–231  ·  view source on GitHub ↗

isJSONNull returns true when the raw JSON encodes a literal `null`, with any surrounding whitespace tolerated.

(raw json.RawMessage)

Source from the content-addressed store, hash-verified

226// isJSONNull returns true when the raw JSON encodes a literal `null`, with
227// any surrounding whitespace tolerated.
228func isJSONNull(raw json.RawMessage) bool {
229 s := strings.TrimSpace(string(raw))
230 return s == "null"
231}
232
233// compile-time assertion that ToolBinding messages descriptors implement what we need.
234var _ proto.Message = (*dynamicpb.Message)(nil)

Callers 1

registerToolMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected