fix: Rename assign baseUrl to const and remove property baseUrl

This commit is contained in:
Toray Altas 2025-12-25 19:03:55 -05:00
parent 32310227b0
commit d532401459

View file

@ -40,7 +40,6 @@ export class OpenRouterEmbedder implements IEmbedder {
private readonly defaultModelId: string
private readonly apiKey: string
private readonly maxItemTokens: number
private readonly baseUrl: string = "https://openrouter.ai/api/v1"
private readonly specificProvider?: string
// Global rate limiting state shared across all instances
@ -72,7 +71,7 @@ export class OpenRouterEmbedder implements IEmbedder {
throw new Error(t("embeddings:validation.apiKeyRequired"))
}
let baseUrl = openRouterBaseUrl || "https://openrouter.ai/api/v1"
const baseUrl = openRouterBaseUrl || "https://openrouter.ai/api/v1"
this.apiKey = apiKey
// Only set specificProvider if it's not the default value