mail: make status a tristate

status can be 'passed', 'failed' or 'skipped'. The motivation for this
change is that when using a relay, we can provide a message indicating
why the check was skipped.
This commit is contained in:
Girish Ramakrishnan
2025-06-27 18:51:03 +02:00
parent ec17e58eed
commit 9428cf0d06
4 changed files with 226 additions and 274 deletions
+1 -3
View File
@@ -31,9 +31,7 @@ async function refreshStatus(domain) {
console.error(error);
} else {
domain.status = Object.keys(result).every((k) => {
if (k === 'dns') return Object.keys(result.dns).every(function (k) { return result.dns[k].status; });
if (!('status' in result[k])) return true; // if status is not present, the test was not run
return result[k].status;
return result[k].status === 'passed' || result[k].status === 'skipped';
});
domain.statusCheckDone = true;
}