fix(workflows-sdk): name for when/then step (#10459)

This commit is contained in:
Carlos R. L. Rodrigues authored and GitHub committed 2024-12-05 15:47:42 -03:00
1 parent 7ff3f15d6d
commit 90ae187e09
14 files changed
+234 -50

No files matched your search

@@ -20,6 +20,10 @@ export async function promiseAll<T extends readonly unknown[] | []>(
promises: T,
{ aggregateErrors } = { aggregateErrors: false }
): Promise<{ -readonly [P in keyof T]: Awaited<T[P]> }> {
if (!promises.length) {
return [] as unknown as Promise<{ -readonly [P in keyof T]: Awaited<T[P]> }>
}
const states = await Promise.allSettled(promises)
const rejected = (states as PromiseSettledResult<unknown>[]).filter(