show error when status is error
This commit is contained in:
parent
08c18b8c94
commit
b18a6aa01c
|
@ -260,8 +260,15 @@ var appStates = {
|
|||
appData.views.section = { otp: true };
|
||||
}
|
||||
, status: function () {
|
||||
function exitState() {
|
||||
clearInterval(tok);
|
||||
}
|
||||
|
||||
function updateStatus() {
|
||||
return api.status().then(function (status) {
|
||||
if (status.error) {
|
||||
appData.views.flash.error = status.error.message || JSON.stringify(status.error, null, 2);
|
||||
}
|
||||
var wilddomains = [];
|
||||
var rootdomains = [];
|
||||
var subdomains = [];
|
||||
|
@ -298,9 +305,7 @@ var appStates = {
|
|||
|
||||
return updateStatus().then(function () {
|
||||
appData.views.section = { status: true };
|
||||
return function cancelState() {
|
||||
clearInterval(tok);
|
||||
};
|
||||
return exitState;
|
||||
});
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue