Fix: Destructure APP_TEMPLATES from app-templates module export
The module exports { APP_TEMPLATES, TEMPLATE_CATEGORIES, DIFFICULTY_LEVELS }
but catalog/wizard were receiving the wrapper object, not the array.
This commit is contained in:
@@ -625,14 +625,15 @@ async function createApp() {
|
||||
}));
|
||||
|
||||
// DC-104: App catalog — browse curated templates
|
||||
const { APP_TEMPLATES: templatesArray } = require('./docker/app-templates');
|
||||
apiRouter.use(catalogRoutes({
|
||||
APP_TEMPLATES: require('./docker/app-templates'),
|
||||
APP_TEMPLATES: templatesArray,
|
||||
asyncHandler: ctx.asyncHandler,
|
||||
}));
|
||||
|
||||
// DC-105: Smart defaults wizard
|
||||
apiRouter.use(wizardRoutes({
|
||||
APP_TEMPLATES: require('./docker/app-templates'),
|
||||
APP_TEMPLATES: templatesArray,
|
||||
asyncHandler: ctx.asyncHandler,
|
||||
}));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user