mirror of
https://github.com/farcasclaudiu/openclaw.git
synced 2026-06-28 21:01:43 +03:00
fix: avoid unused custom preferred provider
This commit is contained in:
committed by
Peter Steinberger
parent
e6715bcb64
commit
d44c118334
@@ -379,7 +379,6 @@ export async function runOnboardingWizard(
|
|||||||
includeSkip: true,
|
includeSkip: true,
|
||||||
}));
|
}));
|
||||||
|
|
||||||
let customPreferredProvider: string | undefined;
|
|
||||||
if (authChoice === "custom-api-key") {
|
if (authChoice === "custom-api-key") {
|
||||||
const customResult = await promptCustomApiConfig({
|
const customResult = await promptCustomApiConfig({
|
||||||
prompter,
|
prompter,
|
||||||
@@ -387,7 +386,6 @@ export async function runOnboardingWizard(
|
|||||||
config: nextConfig,
|
config: nextConfig,
|
||||||
});
|
});
|
||||||
nextConfig = customResult.config;
|
nextConfig = customResult.config;
|
||||||
customPreferredProvider = customResult.providerId;
|
|
||||||
} else {
|
} else {
|
||||||
const authResult = await applyAuthChoice({
|
const authResult = await applyAuthChoice({
|
||||||
authChoice,
|
authChoice,
|
||||||
@@ -403,15 +401,14 @@ export async function runOnboardingWizard(
|
|||||||
nextConfig = authResult.config;
|
nextConfig = authResult.config;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (authChoiceFromPrompt) {
|
if (authChoiceFromPrompt && authChoice !== "custom-api-key") {
|
||||||
const modelSelection = await promptDefaultModel({
|
const modelSelection = await promptDefaultModel({
|
||||||
config: nextConfig,
|
config: nextConfig,
|
||||||
prompter,
|
prompter,
|
||||||
allowKeep: true,
|
allowKeep: true,
|
||||||
ignoreAllowlist: true,
|
ignoreAllowlist: true,
|
||||||
includeVllm: true,
|
includeVllm: true,
|
||||||
preferredProvider:
|
preferredProvider: resolvePreferredProviderForAuthChoice(authChoice),
|
||||||
customPreferredProvider ?? resolvePreferredProviderForAuthChoice(authChoice),
|
|
||||||
});
|
});
|
||||||
if (modelSelection.config) {
|
if (modelSelection.config) {
|
||||||
nextConfig = modelSelection.config;
|
nextConfig = modelSelection.config;
|
||||||
|
|||||||
Reference in New Issue
Block a user