fix base stack exists check

pull/289/head
Frostebite 2021-08-10 18:34:18 +01:00
parent 15d5ec4b81
commit f90c906155
3 changed files with 3 additions and 3 deletions

2
dist/index.js vendored
View File

@ -1032,7 +1032,7 @@ class AWSBuildEnvironment {
StackName: baseStackName,
};
let CFState = yield CF.describeStacks(describeStackInput).promise();
const stackExists = CFState.Stacks === null || CFState.Stacks === [];
const stackExists = CFState.Stacks !== null && CFState.Stacks !== [];
if (stackExists) {
yield CF.createStack({
StackName: baseStackName,

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

View File

@ -238,7 +238,7 @@ class AWSBuildEnvironment implements RemoteBuilderProviderInterface {
StackName: baseStackName,
};
let CFState = await CF.describeStacks(describeStackInput).promise();
const stackExists: Boolean = CFState.Stacks === null || CFState.Stacks === [];
const stackExists: Boolean = CFState.Stacks !== null && CFState.Stacks !== [];
if (stackExists) {
await CF.createStack({
StackName: baseStackName,