MCPcopy Create free account
hub / github.com/fastify/fastify / validateSchemaErrorFormatter

Function validateSchemaErrorFormatter

fastify.js:991–997  ·  view source on GitHub ↗
(schemaErrorFormatter)

Source from the content-addressed store, hash-verified

989}
990
991function validateSchemaErrorFormatter (schemaErrorFormatter) {
992 if (typeof schemaErrorFormatter !== 'function') {
993 throw new FST_ERR_SCHEMA_ERROR_FORMATTER_NOT_FN(typeof schemaErrorFormatter)
994 } else if (schemaErrorFormatter.constructor.name === 'AsyncFunction') {
995 throw new FST_ERR_SCHEMA_ERROR_FORMATTER_NOT_FN('AsyncFunction')
996 }
997}
998
999/**
1000 * These export configurations enable JS and TS developers

Callers 2

fastifyFunction · 0.85
setSchemaErrorFormatterFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected