Add audit / block health config feature flag

This commit is contained in:
Mononaut
2023-02-12 21:43:12 -06:00
committed by nymkappa
parent 72a023af74
commit e12bfa2651
19 changed files with 88 additions and 57 deletions

View File

@@ -211,9 +211,11 @@ class Blocks {
};
}
const auditScore = await BlocksAuditsRepository.$getBlockAuditScore(block.id);
if (auditScore != null) {
blockExtended.extras.matchRate = auditScore.matchRate;
if (config.MEMPOOL.AUDIT) {
const auditScore = await BlocksAuditsRepository.$getBlockAuditScore(block.id);
if (auditScore != null) {
blockExtended.extras.matchRate = auditScore.matchRate;
}
}
}