From 66914df2c7de92ab6fc6f0c0823b57b20164c3b7 Mon Sep 17 00:00:00 2001 From: Brian Madison Date: Wed, 8 Apr 2026 00:38:34 -0500 Subject: [PATCH] fix: use defaults for new config fields during quick update When quick update encounters new config fields (e.g., from a newly supported community module), use schema defaults silently instead of prompting the user. Quick update should be non-interactive. --- tools/installer/modules/official-modules.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/tools/installer/modules/official-modules.js b/tools/installer/modules/official-modules.js index aa709ee45..6b9f76059 100644 --- a/tools/installer/modules/official-modules.js +++ b/tools/installer/modules/official-modules.js @@ -1147,7 +1147,13 @@ class OfficialModules { // Collect all answers (static + prompted) let allAnswers = { ...staticAnswers }; - if (questions.length > 0) { + if (questions.length > 0 && silentMode) { + // In silent mode (quick update), use defaults for new fields instead of prompting + for (const q of questions) { + allAnswers[q.name] = typeof q.default === 'function' ? q.default({}) : q.default; + } + await prompts.log.message(` \u2713 ${moduleName.toUpperCase()} module configured with defaults`); + } else if (questions.length > 0) { // Only show header if we actually have questions await CLIUtils.displayModuleConfigHeader(moduleName, moduleConfig.header, moduleConfig.subheader); await prompts.log.message('');