possibly handle nested secrets in arrrays
This commit is contained in:
parent
7dab73e9bd
commit
2b6cd7af2c
1 changed files with 9 additions and 1 deletions
|
|
@ -109,7 +109,15 @@ async function processSecrets(
|
|||
delete result[key];
|
||||
}
|
||||
}
|
||||
} else if (value && typeof value === "object" && !Array.isArray(value)) {
|
||||
} else if (Array.isArray(value)) {
|
||||
result[key] = await Promise.all(
|
||||
value.map(async (item) =>
|
||||
item && typeof item === "object" && !Array.isArray(item)
|
||||
? processSecrets(item as Record<string, unknown>, secretsMode)
|
||||
: item
|
||||
)
|
||||
);
|
||||
} else if (value && typeof value === "object") {
|
||||
result[key] = await processSecrets(value as Record<string, unknown>, secretsMode);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue