Skip to content

Commit 15c3955

Browse files
authored
fix(cloudformation-diff): cdk diff fails on node14 (#28067)
Some folks are still stuck on node14. Replacing `.at()` with conventional array access to make it easier for them. In this particular instance there's really no benefit to the code using it. But seriously, y'all should upgrade to a current, supported version like Node.js 18. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
1 parent f7b8096 commit 15c3955

File tree

1 file changed

+1
-1
lines changed
  • packages/@aws-cdk/cloudformation-diff/lib/diff

1 file changed

+1
-1
lines changed

packages/@aws-cdk/cloudformation-diff/lib/diff/util.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,5 +184,5 @@ function database(): SpecDatabase {
184184
* The database is loaded lazily and cached across multiple calls to `loadResourceModel`.
185185
*/
186186
export function loadResourceModel(type: string): Resource | undefined {
187-
return database().lookup('resource', 'cloudFormationType', 'equals', type).at(0);
187+
return database().lookup('resource', 'cloudFormationType', 'equals', type)[0];
188188
}

0 commit comments

Comments
 (0)