MCPcopy
hub / github.com/fastify/fastify / setSchemaController

Function setSchemaController

fastify.js:748–759  ·  fastify.js::setSchemaController
(schemaControllerOpts)

Source from the content-addressed store, hash-verified

746 }
747
748 function setSchemaController (schemaControllerOpts) {
749 throwIfAlreadyStarted(class="st">'Cannot call "setSchemaController"!')
750 const old = this[kSchemaController]
751 const schemaController = SchemaController.buildSchemaController(
752 old,
753 Object.assign({}, old.opts, schemaControllerOpts)
754 )
755 this[kSchemaController] = schemaController
756 this.getSchema = schemaController.getSchema.bind(schemaController)
757 this.getSchemas = schemaController.getSchemas.bind(schemaController)
758 return this
759 }
760
761 function setReplySerializer (replySerializer) {
762 throwIfAlreadyStarted(class="st">'Cannot call "setReplySerializer"!')

Callers

nothing calls this directly

Calls 1

throwIfAlreadyStartedFunction · 0.85

Tested by

no test coverage detected