Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
fix(AWS APIGW): Fix handling of provisionedConcurrency: 0 setting
Fixes #7133
  • Loading branch information
medikoo committed Dec 23, 2019
1 parent 702fb92 commit efe6d02
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Expand Up @@ -38,12 +38,12 @@ module.exports = {
);
const lambdaLogicalId = this.provider.naming.getLambdaLogicalId(event.functionName);
const functionObject = this.serverless.service.functions[event.functionName];
const lambdaAliasName =
functionObject.provisionedConcurrency &&
this.provider.naming.getLambdaProvisionedConcurrencyAliasName();
const lambdaAliasLogicalId =
functionObject.provisionedConcurrency &&
this.provider.naming.getLambdaProvisionedConcurrencyAliasLogicalId(event.functionName);
const lambdaAliasName = functionObject.provisionedConcurrency
? this.provider.naming.getLambdaProvisionedConcurrencyAliasName()
: null;
const lambdaAliasLogicalId = functionObject.provisionedConcurrency
? this.provider.naming.getLambdaProvisionedConcurrencyAliasLogicalId(event.functionName)
: null;

const singlePermissionMapping = {
resourceName,
Expand Down
Expand Up @@ -46,7 +46,7 @@ module.exports = {
],
},
},
DependsOn: lambdaAliasLogicalId,
DependsOn: lambdaAliasLogicalId || undefined,
},
});

Expand Down

0 comments on commit efe6d02

Please sign in to comment.