fix(webhooks): fix build error from union type indexing in processTriggerFileOutputs

Cast array initializer to Record<string, unknown> to allow string indexing
while preserving array runtime semantics for the return value.
This commit is contained in:
Waleed Latif
2026-04-04 21:01:48 -07:00
parent ffa586459b
commit 403e32ff33

View File

@@ -69,7 +69,7 @@ async function processTriggerFileOutputs(
return input
}
const processed: Record<string, unknown> | unknown[] = Array.isArray(input) ? [] : {}
const processed = (Array.isArray(input) ? [] : {}) as Record<string, unknown>
for (const [key, value] of Object.entries(input)) {
const currentPath = path ? `${path}.${key}` : key