info should be an object

This commit is contained in:
Karol Wypchlo 2020-08-26 16:45:25 +02:00
parent f201f9c4b4
commit 9ad39482ad
1 changed files with 3 additions and 6 deletions

View File

@ -251,18 +251,15 @@ function skylinkVerification(done, linkInfo) {
up = up && validBody && validMetadata;
}
let info = "";
if (!up) {
info = "validBody: " + validBody + "\nvalidMetadata: " + validMetadata;
}
const info = { validBody, validMetadata };
// Return the entry information
done({
name: linkInfo.description,
up: up,
up,
info,
statusCode,
time: checks.catchRequestTime(time),
info: info,
critical: true,
});
});