Skip to content

Commit

Permalink
fix(cli): fix broken sample-app templates for TypeScript and JavaScri…
Browse files Browse the repository at this point in the history
…pt (#3101)
  • Loading branch information
kpiljoong authored and Elad Ben-Israel committed Jun 27, 2019
1 parent 12e6380 commit 800ecf2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const sns = require('@aws-cdk/aws-sns');
const subs = require('@aws-cdk/aws-sns-subscribers');
const subs = require('@aws-cdk/aws-sns-subscriptions');
const sqs = require('@aws-cdk/aws-sqs');
const cdk = require('@aws-cdk/core');

Expand All @@ -13,12 +13,12 @@ class %name.PascalCased%Stack extends cdk.Stack {
super(scope, id, props);

const queue = new sqs.Queue(this, '%name.PascalCased%Queue', {
visibilityTimeoutSec: 300
visibilityTimeout: cdk.Duration.seconds(300)
});

const topic = new sns.Topic(this, '%name.PascalCased%Topic');

topic.subscribe(new subs.SqsSubscriber(queue));
topic.addSubscription(new subs.SqsSubscription(queue));
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import sns = require('@aws-cdk/aws-sns');
const subs = require('@aws-cdk/aws-sns-subscriptions');
import subs = require('@aws-cdk/aws-sns-subscriptions');
import sqs = require('@aws-cdk/aws-sqs');
import cdk = require('@aws-cdk/core');

Expand All @@ -8,7 +8,7 @@ export class %name.PascalCased%Stack extends cdk.Stack {
super(scope, id, props);

const queue = new sqs.Queue(this, '%name.PascalCased%Queue', {
visibilityTimeoutSec: 300
visibilityTimeout: cdk.Duration.seconds(300)
});

const topic = new sns.Topic(this, '%name.PascalCased%Topic');
Expand Down

0 comments on commit 800ecf2

Please sign in to comment.