Skip to content

Commit

Permalink
Fix: ServerlessError: Export 'project-name-ServerlessAliasReference' …
Browse files Browse the repository at this point in the history
…does not exist.
  • Loading branch information
Sergii Kovalev committed Mar 25, 2020
1 parent a023ac5 commit 44d858b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/stackInformation.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,9 @@ module.exports = {
.mapSeries(stack => BbPromise.join(BbPromise.resolve(stack), this.aliasStackLoadTemplate(stack)))
.map(stackInfo => ({ stack: stackInfo[0], template: stackInfo[1] }))
.catch(err => {
if (err.statusCode === 400) {
if (err.statusCode === 400
|| (err.statusCode === undefined && err.providerError && err.providerError.statusCode === 400)
) {
// The export is not yet there. Can happen on the very first alias stack deployment.
return BbPromise.resolve([]);
}
Expand Down

0 comments on commit 44d858b

Please sign in to comment.