Skip to content

Commit e784a29

Browse files
authored
Merge pull request #163 from aleksdikanski/bug/159_fix_util_functions
replace equals with startsWith in util functions
2 parents e12d157 + 22581a0 commit e784a29

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/utils.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ class Utils {
111111
* @returns {string}
112112
*/
113113
static getFunctionVersionName(versions, functionName) {
114-
return _.find(_.keys(versions), version => version === `${functionName}LambdaVersion`);
114+
return _.find(_.keys(versions), version => _.startsWith(version, `${functionName}LambdaVersion`));
115115
}
116116

117117
/**
@@ -120,7 +120,7 @@ class Utils {
120120
* @returns {string}
121121
*/
122122
static getAliasVersionName(aliases, functionName) {
123-
return _.find(_.keys(aliases), alias => alias === `${functionName}Alias`);
123+
return _.find(_.keys(aliases), alias => _.startsWith(alias, `${functionName}Alias`));
124124
}
125125
}
126126

0 commit comments

Comments
 (0)