1
0
mirror of https://github.com/Unleash/unleash.git synced 2024-12-28 00:06:53 +01:00
unleash.unleash/lib/services/state-schema.js

21 lines
491 B
JavaScript
Raw Normal View History

const joi = require('joi');
const { featureShema } = require('../routes/admin-api/feature-schema');
const strategySchema = require('../routes/admin-api/strategy-schema');
// TODO: Extract to seperate file
const stateSchema = joi.object().keys({
version: joi.number(),
features: joi
.array()
.optional()
.items(featureShema),
strategies: joi
.array()
.optional()
.items(strategySchema),
});
module.exports = {
stateSchema,
};