From cc6b679d627171fb6f0fc42cfef0742bc02ca5e4 Mon Sep 17 00:00:00 2001 From: Qwerty5Uiop Date: Fri, 20 May 2022 21:37:28 +0400 Subject: [PATCH] Fixed burned_fees manual reward calculation --- apps/explorer/lib/explorer/chain.ex | 1 - apps/explorer/test/explorer/chain_test.exs | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/apps/explorer/lib/explorer/chain.ex b/apps/explorer/lib/explorer/chain.ex index eb8a229443..ef59afd7bb 100644 --- a/apps/explorer/lib/explorer/chain.ex +++ b/apps/explorer/lib/explorer/chain.ex @@ -824,7 +824,6 @@ defmodule Explorer.Chain do burned_fee_counter = transactions - |> Enum.filter(fn tx -> not is_nil(Map.get(tx, :max_priority_fee_per_gas)) end) |> Enum.reduce(Decimal.new(0), fn %{gas_used: gas_used}, acc -> gas_used |> Decimal.new() diff --git a/apps/explorer/test/explorer/chain_test.exs b/apps/explorer/test/explorer/chain_test.exs index 7b42556c8f..a9920dd8fc 100644 --- a/apps/explorer/test/explorer/chain_test.exs +++ b/apps/explorer/test/explorer/chain_test.exs @@ -3436,7 +3436,7 @@ defmodule Explorer.ChainTest do ) expected_txn_fees = %Wei{value: Decimal.new(6)} - expected_burned_fees = %Wei{value: Decimal.new(15)} + expected_burned_fees = %Wei{value: Decimal.new(30)} expected_uncle_reward = %Wei{value: Decimal.new(0)} assert %{