Add blocks.extras.totalFees and show it in blockchain blocks component

This commit is contained in:
nymkappa committed 2022-02-22 23:57:54 +09:00
1 parent 201eff593b
commit c1092adfd9
4 files changed
+6 -1

No files matched your search

+3
View File
@@ -116,6 +116,9 @@ class Blocks {
Common.median(transactionsTmp.map((tx) => tx.effectiveFeePerVsize)) : 0;
blockExtended.extras.feeRange = transactionsTmp.length > 0 ?
Common.getFeesInRange(transactionsTmp, 8) : [0, 0];
blockExtended.extras.totalFees = transactionsTmp.reduce((acc, tx) => {
return acc + tx.fee;
}, 0)
if (Common.indexingEnabled()) {
let pool: PoolTag;