in browser/scripts/gov-cloud-import-browser.js [215:239]
function watchGovCloudFormation(refreshIdGov, govCloudFormation, config){
return new Promise((resolve, reject) => {
let date = new Date();
let params = {
StackName: 'gov-cloud-import'
};
govCloudFormation.describeStacks(params, function(err, data) {
if (err) {
resolve(err.message);
} else {
if (data.Stacks[0].StackStatus == "DELETE_COMPLETE") {
refreshInstallStatus();
clearInterval(refreshIdGov);
} else if (data.Stacks[0].StackStatus = "DELETE_FAILED"){
refreshInstallStatus();
clearInterval(refreshIdGov);
} else if (data.Stacks[0].StackStatus = "CREATE_COMPLETE"){
refreshInstallStatus();
clearInterval(refreshIdGov);
}
resolve(data.Stacks[0].StackStatus)
}
});
});
}