mirror of
https://github.com/Yidadaa/ChatGPT-Next-Web.git
synced 2025-08-10 05:30:02 +08:00
fix: fix add api auth
This commit is contained in:
@@ -145,8 +145,8 @@ export function getHeaders() {
|
||||
"Content-Type": "application/json",
|
||||
"x-requested-with": "XMLHttpRequest",
|
||||
};
|
||||
|
||||
const isGoogle = accessStore.provider === ServiceProvider.Google;
|
||||
const modelConfig = useChatStore.getState().currentSession().mask.modelConfig;
|
||||
const isGoogle = modelConfig.model === "gemini";
|
||||
const isAzure = accessStore.provider === ServiceProvider.Azure;
|
||||
const authHeader = isAzure ? "api-key" : "Authorization";
|
||||
const apiKey = isGoogle
|
||||
|
Reference in New Issue
Block a user