Skip to content

Commit

Permalink
hotfix cc resources
Browse files Browse the repository at this point in the history
  • Loading branch information
jfrconley committed Sep 17, 2024
1 parent 1a51187 commit 56375fe
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/tidy-walls-change.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@nrfcloud/cdktf-aws-adaptor": patch
---

hotfix cloudcontrol resources
4 changes: 2 additions & 2 deletions src/mappings/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,10 @@ export function createGenericCCApiMapping(
}

return {
resource: (scope, id, props) => {
resource: (scope, id, props, proxy) => {
proxy.touchPath("*");
// clone object as we have to delete props from the original one
const desiredState = Fn.jsonencode({ ...props });
for (const key of Object.keys(props)) delete props[key];

return new CloudcontrolapiResource(scope, id, {
desiredState,
Expand Down

0 comments on commit 56375fe

Please sign in to comment.