[RFC] refactor: remove vestigial generic type parameters from Protocol, Server, and Client (#1451)

This commit is contained in:
Felix Weinberger 2026-02-03 20:55:32 +00:00 • committed by GitHub
commit faeb03ec17
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -293,7 +293,7 @@ async function connect(url?: string): Promise<void> {
attempts++;
console.log(`\nPlease provide the following information (attempt ${attempts}/${maxAttempts}):`);
const content: Record<string, unknown> = {};
const content: Record<string, string | number | boolean | string[]> = {};
let inputCancelled = false;
// Collect input for each field
@ -357,7 +357,7 @@ async function connect(url?: string): Promise<void> {
// Parse and validate the input
try {
if (answer === '' && field.default !== undefined) {
content[fieldName] = field.default;
content[fieldName] = field.default as string | number | boolean | string[];
} else if (answer === '' && !isRequired) {
// Skip optional empty fields
continue;
@ -401,7 +401,7 @@ async function connect(url?: string): Promise<void> {
}
}
content[fieldName] = parsedValue;
content[fieldName] = parsedValue as string | number | boolean | string[];
}
} catch (error) {
console.log(`❌ Error: ${error}`);