mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-05-28 18:26:54 +00:00
fix(scripts): ignore upcoming blocks when building external curricula (#61345)
This commit is contained in:
@@ -305,13 +305,17 @@ export function buildExtCurriculumDataV2(
|
|||||||
moduleType: module.moduleType,
|
moduleType: module.moduleType,
|
||||||
blocks: module.comingSoon
|
blocks: module.comingSoon
|
||||||
? []
|
? []
|
||||||
: module.blocks.map(block => {
|
: module.blocks
|
||||||
const blockData = blocksWithData[block.dashedName];
|
// Upcoming blocks aren't included in blocksWithData
|
||||||
return {
|
// and thus they have no metadata and need to be filtered out.
|
||||||
intro: superBlockIntros.blocks[block.dashedName].intro,
|
.filter(block => blocksWithData[block.dashedName])
|
||||||
meta: blockData.meta
|
.map(block => {
|
||||||
};
|
const blockData = blocksWithData[block.dashedName];
|
||||||
})
|
return {
|
||||||
|
intro: superBlockIntros.blocks[block.dashedName].intro,
|
||||||
|
meta: blockData.meta
|
||||||
|
};
|
||||||
|
})
|
||||||
}))
|
}))
|
||||||
}));
|
}));
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user