From 8af58ab8078c6f0f1a486de537a8da49a64a330e Mon Sep 17 00:00:00 2001 From: Adam Ruka Date: Tue, 22 Sep 2020 10:01:54 -0700 Subject: [PATCH] Make the "branch is Token" EventId always different from the "branch is not Token" case --- .../aws-codepipeline-actions/lib/codecommit/source-action.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/@aws-cdk/aws-codepipeline-actions/lib/codecommit/source-action.ts b/packages/@aws-cdk/aws-codepipeline-actions/lib/codecommit/source-action.ts index a61743e6995ec..591609252ba68 100644 --- a/packages/@aws-cdk/aws-codepipeline-actions/lib/codecommit/source-action.ts +++ b/packages/@aws-cdk/aws-codepipeline-actions/lib/codecommit/source-action.ts @@ -160,7 +160,7 @@ export class CodeCommitSourceAction extends Action { let candidate = ''; let counter = 0; do { - candidate = this.eventIdFromPrefix(`${baseId}-Branch${counter}-`); + candidate = this.eventIdFromPrefix(`${baseId}{counter}`); counter += 1; } while (this.props.repository.node.tryFindChild(candidate) !== undefined); return candidate;