Prevent null proofs from displaying

This commit is contained in:
Yarmo Mackenbach 2020-07-16 19:46:27 +02:00
parent 0dacc5acc3
commit 0783731d47

View file

@ -313,10 +313,13 @@ async function displayProfile(opts) {
}
// Verify identity proofs
let proofResult;
for (var i = 0; i < keyData.notations.length; i++) {
notation = keyData.notations[i];
if (notation[0] != "proof@metacode.biz") { continue; }
verifications.push(await verifyProof(notation[1], keyData.fingerprint));
proofResult = await verifyProof(notation[1], keyData.fingerprint);
if (!proofResult || !proofResult.display) { continue; }
verifications.push(proofResult);
}
// One-line sorting function (order verifications by type)