Skip to content

Commit

Permalink
fix: fix bug in generating wrong gemini request url
Browse files Browse the repository at this point in the history
  • Loading branch information
yeung66 committed Jul 18, 2024
1 parent ee22fba commit 26c2598
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions app/client/platforms/google.ts
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,10 @@ export class GeminiProApi implements LLMApi {
const controller = new AbortController();
options.onController?.(controller);
try {
if (!baseUrl && isApp) {
baseUrl = DEFAULT_API_HOST + "/api/proxy/google/";
if (!baseUrl) {
baseUrl = isApp
? DEFAULT_API_HOST + "/api/proxy/google/"
: this.path("");
}
baseUrl = `${baseUrl}/${Google.ChatPath(modelConfig.model)}`.replaceAll(
"//",
Expand Down

0 comments on commit 26c2598

Please sign in to comment.