Update config-manager.js

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
Steven Mosley 2025-09-23 18:48:38 -05:00 committed by GitHub
parent 0286c46f17
commit c19eeeb0b0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -293,20 +293,12 @@ function getEffectivelyEnabledItems(config) {
chatmodes: new Set()
};
for (const itemName in effectiveStates.prompts) {
if (effectiveStates.prompts[itemName].enabled) {
result.prompts.add(itemName);
for (const section of ["prompts", "instructions", "chatmodes"]) {
for (const itemName in effectiveStates[section]) {
if (effectiveStates[section][itemName].enabled) {
result[section].add(itemName);
}
}
for (const itemName in effectiveStates.instructions) {
if (effectiveStates.instructions[itemName].enabled) {
result.instructions.add(itemName);
}
}
for (const itemName in effectiveStates.chatmodes) {
if (effectiveStates.chatmodes[itemName].enabled) {
result.chatmodes.add(itemName);
}
}
return result;
}