MCPcopy Index your code
hub / github.com/fastify/fast-json-stringify / getSafeSchemaRef

Function getSafeSchemaRef

index.js:97–103  ·  view source on GitHub ↗
(context, location)

Source from the content-addressed store, hash-verified

95}
96
97function getSafeSchemaRef (context, location) {
98 let schemaRef = location.getSchemaRef() || ''
99 if (schemaRef.startsWith(context.rootSchemaId)) {
100 schemaRef = schemaRef.replace(context.rootSchemaId, '') || '#'
101 }
102 return schemaRef
103}
104
105function build (schema, options) {
106 isValidSchema(schema)

Callers 4

buildObjectFunction · 0.85
buildArrayFunction · 0.85
buildMultiTypeSerializerFunction · 0.85
buildOneOfFunction · 0.85

Calls 1

getSchemaRefMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…