fix: fix bug in generating wrong gemini request url
This commit is contained in:
parent
ee22fba448
commit
26c2598f56
|
@ -123,8 +123,10 @@ export class GeminiProApi implements LLMApi {
|
||||||
const controller = new AbortController();
|
const controller = new AbortController();
|
||||||
options.onController?.(controller);
|
options.onController?.(controller);
|
||||||
try {
|
try {
|
||||||
if (!baseUrl && isApp) {
|
if (!baseUrl) {
|
||||||
baseUrl = DEFAULT_API_HOST + "/api/proxy/google/";
|
baseUrl = isApp
|
||||||
|
? DEFAULT_API_HOST + "/api/proxy/google/"
|
||||||
|
: this.path("");
|
||||||
}
|
}
|
||||||
baseUrl = `${baseUrl}/${Google.ChatPath(modelConfig.model)}`.replaceAll(
|
baseUrl = `${baseUrl}/${Google.ChatPath(modelConfig.model)}`.replaceAll(
|
||||||
"//",
|
"//",
|
||||||
|
|
Loading…
Reference in New Issue