mirror of
https://github.com/getcompanion-ai/co-mono.git
synced 2026-04-15 21:03:19 +00:00
fix(tools.ts): sync with active tools when no saved state
Hook was showing all tools as enabled even though only 4 were active. Now initializes from pi.getActiveTools() to match actual state.
This commit is contained in:
parent
31438fdf2a
commit
b06bd1d24c
1 changed files with 2 additions and 2 deletions
|
|
@ -57,8 +57,8 @@ export default function toolsHook(pi: HookAPI) {
|
|||
enabledTools = new Set(savedTools.filter((t: string) => allTools.includes(t)));
|
||||
applyTools();
|
||||
} else {
|
||||
// No saved state - enable all tools by default
|
||||
enabledTools = new Set(allTools);
|
||||
// No saved state - sync with currently active tools
|
||||
enabledTools = new Set(pi.getActiveTools());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue