fix(client): handle builds without all challenges (#61040)

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
This commit is contained in:
Oliver Eyton-Williams
2025-10-02 16:44:27 +02:00
committed by GitHub
parent 568840b8d8
commit 517b9f0576
5 changed files with 95 additions and 32 deletions
-3
View File
@@ -162,7 +162,6 @@ const schema = Joi.object().keys({
}),
certification: Joi.string().regex(slugWithSlashRE),
challengeType: Joi.number().min(0).max(31).required(),
checksum: Joi.number(),
// TODO: require this only for normal challenges, not certs
dashedName: Joi.string().regex(slugRE),
demoType: Joi.string().valid('onClick', 'onLoad'),
@@ -183,7 +182,6 @@ const schema = Joi.object().keys({
then: Joi.string()
}),
challengeFiles: Joi.array().items(fileJoi),
guideUrl: Joi.string().uri({ scheme: 'https' }),
hasEditableBoundaries: Joi.boolean(),
helpCategory: Joi.valid(
'JavaScript',
@@ -217,7 +215,6 @@ const schema = Joi.object().keys({
otherwise: Joi.string().allow('')
}),
isComingSoon: Joi.bool(),
isLocked: Joi.bool(),
module: Joi.string().when('superBlock', {
is: chapterBasedSuperBlocks,
then: Joi.required(),