Skip to content

Commit

Permalink
Fix incorrect hashrate computation for status endpoint (#4272)
Browse files Browse the repository at this point in the history
  • Loading branch information
hanssv committed Feb 28, 2024
1 parent 01dd226 commit ca78e77
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/aehttp/src/aehttp_dispatch_ext.erl
Original file line number Diff line number Diff line change
Expand Up @@ -843,7 +843,7 @@ target_to_hashrate(Target, aec_consensus_bitcoin_ng) ->
0 -> 0;
_ ->
Difficulty = aeminer_pow:target_to_difficulty(Target) / (1 bsl 24),
round(Difficulty * (aec_governance:expected_block_mine_rate() / 1000) * 42)
round((Difficulty * 42) / (aec_governance:expected_block_mine_rate() / 1000))
end;
target_to_hashrate(_Target, _Consensus) ->
0.
Expand Down

0 comments on commit ca78e77

Please sign in to comment.