diff --git a/packages/aws-cdk/lib/list-stacks.ts b/packages/aws-cdk/lib/list-stacks.ts index 533204adaf608..e76a1f393a0a9 100644 --- a/packages/aws-cdk/lib/list-stacks.ts +++ b/packages/aws-cdk/lib/list-stacks.ts @@ -81,7 +81,7 @@ export async function listStacks(toolkit: CdkToolkit, options: ListStacksOptions }); } } else { - data.dependencies?.push({ + data.dependencies.push({ id: depStack.stackArtifacts[0].id, dependencies: [], });