Skip to content

Commit 73a0cd6

Browse files
author
Aleksander Dikanski
committed
Fix error with unsupported StageName property
1 parent 5546e38 commit 73a0cd6

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

lib/stackops/apiGateway.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ module.exports = function(currentTemplate, aliasStackTemplates, currentAliasStac
192192
const baseMappingName = _.keys(baseMapping)[0];
193193
const obj = baseMapping[baseMappingName];
194194

195-
obj.Properties.StageName = { Ref: 'ApiGatewayStage' };
195+
obj.Properties.Stage = { Ref: 'ApiGatewayStage' };
196196
obj.Properties.RestApiId = { 'Fn::ImportValue': `${stackName}-ApiGatewayRestApi`};
197197

198198
aliasResources.push(baseMapping);

test/stackops/apiGateway.test.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -749,8 +749,7 @@ describe('API Gateway', () => {
749749
BasePath: '(none)',
750750
DomainName: 'example.com',
751751
RestApiId: { 'Fn::ImportValue': 'testService-myStage-ApiGatewayRestApi' },
752-
StageName: { Ref: 'ApiGatewayStage' },
753-
Stage: 'test'
752+
Stage: { Ref: 'ApiGatewayStage' }
754753
}
755754
})
756755
]));

0 commit comments

Comments
 (0)