mirror of
https://github.com/diegosouzapw/OmniRoute.git
synced 2026-08-06 07:12:12 +03:00
fix: drop provider prefix from static-catalog model dict keys (#9178)
Validated in local merge-train (devbox-vm-06-dev002) @ combined-tip (FAST gates green: static + changed tests + vitest — only pre-existing audit.test.ts flake). Evidence: /home/diegosouzapw/dev/proxys/OmniRoute/.claude/worktrees/merge-train-20260805-213228-suite.log
This commit is contained in:
@@ -4271,7 +4271,7 @@ export function buildStaticProviderEntry(
|
||||
// has no corresponding provider block. So bare keys (no `/`) MUST be
|
||||
// prefixed with the resolved providerId. Already-prefixed keys
|
||||
// (e.g. `cc/claude-opus-4-7`) are left as-is to avoid double-prefixing.
|
||||
models[raw.id.includes("/") ? raw.id : `${opts.providerId}/${raw.id}`] = entry;
|
||||
models[raw.id] = entry;
|
||||
}
|
||||
|
||||
// Combo entries → stripped LCD shape. Each combo is keyed as
|
||||
@@ -4466,7 +4466,7 @@ export function buildStaticProviderEntry(
|
||||
// (`opencode-omniroute/opencode-omniroute/<slug>`), and `parseModel()`
|
||||
// resolves credentials for the nonexistent provider `opencode-omniroute`
|
||||
// instead of `omniroute`. See #7976.
|
||||
models[buildComboKey(combo, usedComboKeys, opts.omnirouteProviderId)] = entry;
|
||||
models[buildComboKey(combo, usedComboKeys, opts.omnirouteProviderId).split("/").pop()!] = entry;
|
||||
|
||||
// Make this combo's resolved entry available to parent combos
|
||||
// that reference it via combo-ref. Use the friendly name since
|
||||
|
||||
Reference in New Issue
Block a user