Update src/core/prompts/sections/modes.ts

Co-authored-by: Matt Rubens <mrubens@users.noreply.github.com>
This commit is contained in:
Hannes Rudolph 2025-03-08 22:31:10 -07:00 committed by GitHub
parent 2a08c7c3db
commit f6efa2b589
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -12,9 +12,7 @@ export async function getModesSection(context: vscode.ExtensionContext): Promise
const allModes = await getAllModesWithPrompts(context)
// Get enableCustomModeCreation setting from extension state
const enableCustomModeCreation = await context.globalState.get<boolean>("enableCustomModeCreation")
// Default to true if undefined
const shouldEnableCustomModeCreation = enableCustomModeCreation !== undefined ? enableCustomModeCreation : true
const shouldEnableCustomModeCreation = await context.globalState.get<boolean>("enableCustomModeCreation") ?? true
let modesContent = `====