Skip to content

Commit 2fa468d

Browse files
authored
Update to set CfnWebACLAssociation only if addWaf is true (#108)
1 parent 26f400a commit 2fa468d

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

cdk/lib/cognito-passwordless.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1022,11 +1022,11 @@ export class Passwordless extends Construct {
10221022
],
10231023
}
10241024
);
1025+
new cdk.aws_wafv2.CfnWebACLAssociation(scope, `WafAssociation${id}`, {
1026+
resourceArn: this.fido2Api.deploymentStage.stageArn,
1027+
webAclArn: this.fido2ApiWebACL.attrArn,
1028+
});
10251029
}
1026-
new cdk.aws_wafv2.CfnWebACLAssociation(scope, `WafAssociation${id}`, {
1027-
resourceArn: this.fido2Api.deploymentStage.stageArn,
1028-
webAclArn: this.fido2ApiWebACL!.attrArn,
1029-
});
10301030
}
10311031
}
10321032
}

0 commit comments

Comments
 (0)