Skip to content

Commit 48e7dd5

Browse files
committed
fix(kimi-code): explicit optional resolve arg in execFileText (typecheck)
1 parent 98c9600 commit 48e7dd5

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

apps/kimi-code/src/cli/kaos-local.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,11 @@ export function execFileText(
212212
args: readonly string[],
213213
timeoutMs: number,
214214
): Promise<string | undefined> {
215-
return new Promise((resolve) => {
215+
// `resolve` is explicitly optional-arg so the bare `resolve()` error path
216+
// stays valid: tsc rejects a missing required arg, and oxlint simplifies
217+
// `resolve(undefined)` back to `resolve()` — the explicit signature keeps
218+
// both tools happy.
219+
return new Promise<string | undefined>((resolve: (value?: string | undefined) => void) => {
216220
execFile(
217221
file,
218222
[...args],

0 commit comments

Comments
 (0)