feat: alternative models response support

This commit is contained in:
Timothy J. Baek 2023-12-22 20:31:42 -08:00
parent 0fcdee60cd
commit ecc2466f1e
2 changed files with 6 additions and 2 deletions

View file

@ -323,7 +323,9 @@
return null;
});
const openAIModels = openaiModelRes?.data ?? null;
const openAIModels = Array.isArray(openaiModelRes)
? openaiModelRes
: openaiModelRes?.data ?? null;
models.push(
...(openAIModels

View file

@ -74,7 +74,9 @@
return null;
});
const openAIModels = openaiModelRes?.data ?? null;
const openAIModels = Array.isArray(openaiModelRes)
? openaiModelRes
: openaiModelRes?.data ?? null;
models.push(
...(openAIModels