Merge pull request #3214 from Ensteinjun/main

This commit is contained in:
Yifei Zhang 2023-11-10 15:58:28 +08:00 committed by GitHub
commit 78d68a9949
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -18,7 +18,7 @@ export async function requestOpenai(req: NextRequest) {
); );
let baseUrl = let baseUrl =
serverConfig.azureUrl ?? serverConfig.baseUrl ?? OPENAI_BASE_URL; serverConfig.azureUrl || serverConfig.baseUrl || OPENAI_BASE_URL;
if (!baseUrl.startsWith("http")) { if (!baseUrl.startsWith("http")) {
baseUrl = `https://${baseUrl}`; baseUrl = `https://${baseUrl}`;