Skip to content

Commit 9030102

Browse files
authored
chore(infra): remove redundant default DESTROY removalPolicy (aws-samples#42)
1 parent 7cbe82e commit 9030102

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

packages/infra/cdk/aws-sdk-js-notes-app-stack.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ export class AwsSdkJsNotesAppStack extends cdk.Stack {
1212

1313
const table = new dynamodb.Table(this, "notes", {
1414
partitionKey: { name: "noteId", type: dynamodb.AttributeType.STRING },
15-
removalPolicy: cdk.RemovalPolicy.DESTROY, // NOT recommended for production code
1615
});
1716

1817
const api = new apigw.RestApi(this, "endpoint");
@@ -69,9 +68,7 @@ export class AwsSdkJsNotesAppStack extends cdk.Stack {
6968
)
7069
);
7170

72-
const filesBucket = new s3.Bucket(this, "files-bucket", {
73-
removalPolicy: cdk.RemovalPolicy.DESTROY, // NOT recommended for production code
74-
});
71+
const filesBucket = new s3.Bucket(this, "files-bucket");
7572
filesBucket.addCorsRule({
7673
allowedOrigins: apigw.Cors.ALL_ORIGINS, // NOT recommended for production code
7774
allowedMethods: [

0 commit comments

Comments
 (0)