dashboard-domain.js: perform callback only if update successful

This commit is contained in:
Adhityaa Chandrasekar 2019-04-20 20:33:50 -04:00
parent 45c6361805
commit 536ec14b93

View File

@ -120,14 +120,14 @@
};
global.post(global.origin + "/api/domain/update", json, function(resp) {
if (callback !== undefined) {
callback(resp.success);
}
if (!resp.success) {
global.globalErrorShow(resp.message);
return;
}
if (callback !== undefined) {
callback(resp.success);
}
});
}