Merge pull request #4153 from MoerAI/fix/fallback-model-string-guard
fix(shared,delegate-task,claude-code-agent-loader): guard model parsers against non-string input (fixes #4145)
This commit is contained in:
@@ -11,6 +11,7 @@ const CLAUDE_CODE_ALIAS_MAP = new Map<string, string>([
|
||||
|
||||
function mapClaudeModelString(model: string | undefined): string | undefined {
|
||||
if (!model) return undefined
|
||||
if (typeof model !== "string") return undefined
|
||||
|
||||
const trimmed = model.trim()
|
||||
if (trimmed.length === 0) return undefined
|
||||
|
||||
Reference in New Issue
Block a user