mirror of
https://github.com/j3ssie/osmedeus.git
synced 2026-09-10 11:47:45 +02:00
refactor: optimize ACP agent initialization and remove dead code
- Remove unreachable custom agent command validation from ACPExecutor.Execute() - Add IsBuiltinAgent() utility function for cleaner agent name resolution - Replace inline agent list iteration with IsBuiltinAgent() check in agent_chat.go - Add explicit stdin pipe cleanup in RunAgentACP() defer block - Simplify CLI output handling by removing redundant stream output fallback
This commit is contained in:
@@ -165,10 +165,8 @@ func resolveAgentName(model string) string {
|
||||
if model == "" {
|
||||
return "claude-code"
|
||||
}
|
||||
for _, name := range executor.ListAgentNames() {
|
||||
if name == model {
|
||||
return model
|
||||
}
|
||||
if executor.IsBuiltinAgent(model) {
|
||||
return model
|
||||
}
|
||||
return "claude-code"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user