style: auto-fix ESLint issues (curly braces and formatting)
- Add curly braces to all if/else/for/while statements - Fix indentation and trailing spaces - Auto-fixed 372 linting errors using eslint --fix - Remaining issues are warnings only (non-null assertions, explicit any types)
This commit is contained in:
@@ -41,11 +41,11 @@ async function configureProvider(p: Prompter, def: ProviderDef): Promise<{
|
||||
provider: string; model: string; api_key?: string; endpoint?: string;
|
||||
}> {
|
||||
const help = PROVIDER_HELP[def.provider];
|
||||
if (help) p.println(` ${help}`);
|
||||
if (help) {p.println(` ${help}`);}
|
||||
|
||||
const config: Record<string, string> = { provider: def.provider };
|
||||
if (def.needsApiKey) config.api_key = await p.password(def.apiKeyLabel ?? 'API key');
|
||||
if (def.needsEndpoint) config.endpoint = await p.ask('Host', def.defaultEndpoint);
|
||||
if (def.needsApiKey) {config.api_key = await p.password(def.apiKeyLabel ?? 'API key');}
|
||||
if (def.needsEndpoint) {config.endpoint = await p.ask('Host', def.defaultEndpoint);}
|
||||
config.model = await p.ask('Model', def.defaultModel);
|
||||
return config as { provider: string; model: string; api_key?: string; endpoint?: string };
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user