fix(ui): accept partial raw model records

- allow raw JSON model arrays with partial fields to format safely

- keep the requested=upstream review fixes compatible with raw editor input

Refs #941
This commit is contained in:
Tam Nhu Tran
2026-04-10 17:46:18 -04:00
parent 92a769d773
commit 42d5724f34
+1 -1
View File
@@ -165,7 +165,7 @@ export function getRequestedUpstreamModelRuleErrors(value: string): string[] {
* Format stored provider config back into the UI-facing requested=upstream form.
*/
export function formatRequestedUpstreamModelRules(
models: AiProviderModelAlias[] | null | undefined
models: Array<Partial<AiProviderModelAlias>> | null | undefined
): string {
return (models || [])
.map((item) => {