Fix tsconfig and test folder

This commit is contained in:
2026-03-13 00:28:48 +05:30
parent e913bff33c
commit 814bbc41a7
4 changed files with 35 additions and 8 deletions
+6 -6
View File
@@ -182,15 +182,15 @@ function levenshtein(left: string, right: string): number {
const cost = left[leftIndex - 1] === right[rightIndex - 1] ? 0 : 1;
row[rightIndex] = Math.min(
row[rightIndex] + 1,
row[rightIndex - 1] + 1,
previous + cost,
row[rightIndex]! + 1,
row[rightIndex - 1]! + 1,
previous! + cost,
);
previous = current;
}
}
return row[right.length];
return row[right.length]!;
}
/**
@@ -242,7 +242,7 @@ function suggestModels(requested: string, allowlist: string[]): string[] {
* ```
*/
function formatInvalidModelError(invalidModels: string[], allowlist: string[]): string {
const [firstInvalidModel] = invalidModels;
const firstInvalidModel = invalidModels[0]!;
const suggestions = suggestModels(firstInvalidModel, allowlist);
const suggestionText =
suggestions.length > 0
@@ -369,7 +369,7 @@ export default tool({
const failedModels: string[] = [];
for (let i = 0; i < windowPlans.length; i++) {
const plan = windowPlans[i];
const plan = windowPlans[i]!;
const isFirst = i === 0;
const worktreePath = getWorktreePath(safeSessionName, plan.windowName);