travel/admin/node_modules/@hapi/joi/lib/schemas.js

21 lines
561 B
JavaScript
Raw Normal View History

2024-06-24 11:28:18 +08:00
'use strict';
const Joi = require('./index');
const internals = {};
exports.options = Joi.object({
abortEarly: Joi.boolean(),
convert: Joi.boolean(),
allowUnknown: Joi.boolean(),
skipFunctions: Joi.boolean(),
stripUnknown: [Joi.boolean(), Joi.object({ arrays: Joi.boolean(), objects: Joi.boolean() }).or('arrays', 'objects')],
language: Joi.object(),
presence: Joi.string().only('required', 'optional', 'forbidden', 'ignore'),
context: Joi.object(),
noDefaults: Joi.boolean(),
escapeHtml: Joi.boolean()
}).strict();