mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-08 20:28:29 +00:00
fix: keep Moonshot CN base URL in onboarding (#7180) (thanks @waynelwz)
This commit is contained in:
@@ -18,6 +18,7 @@ import {
|
||||
applyMoonshotConfig,
|
||||
applyMoonshotConfigCn,
|
||||
applyMoonshotProviderConfig,
|
||||
applyMoonshotProviderConfigCn,
|
||||
applyOpencodeZenConfig,
|
||||
applyOpencodeZenProviderConfig,
|
||||
applyOpenrouterConfig,
|
||||
@@ -314,7 +315,7 @@ export async function applyAuthChoiceApiProviders(
|
||||
setDefaultModel: params.setDefaultModel,
|
||||
defaultModel: MOONSHOT_DEFAULT_MODEL_REF,
|
||||
applyDefaultConfig: applyMoonshotConfigCn,
|
||||
applyProviderConfig: (cfg) => applyMoonshotProviderConfigCnShim(cfg),
|
||||
applyProviderConfig: applyMoonshotProviderConfigCn,
|
||||
noteAgentModel,
|
||||
prompter: params.prompter,
|
||||
});
|
||||
@@ -324,14 +325,6 @@ export async function applyAuthChoiceApiProviders(
|
||||
return { config: nextConfig, agentModelOverride };
|
||||
}
|
||||
|
||||
function applyMoonshotProviderConfigCnShim(
|
||||
cfg: Parameters<typeof applyMoonshotProviderConfig>[0],
|
||||
) {
|
||||
// For now, provider-level CN behavior is fully handled inside applyMoonshotConfigCn.
|
||||
// Keep a thin shim to satisfy the applyDefaultModelChoice signature.
|
||||
return applyMoonshotProviderConfig(cfg);
|
||||
}
|
||||
|
||||
if (authChoice === "kimi-code-api-key") {
|
||||
let hasCredential = false;
|
||||
const tokenProvider = params.opts?.tokenProvider?.trim().toLowerCase();
|
||||
|
||||
Reference in New Issue
Block a user