Fix: Reduce red difficulty adjustment progress when nearing end of cycle.

This commit is contained in:
softsimon 2020-11-02 14:48:48 +07:00
parent 73acec23ae
commit 6865e00738
No known key found for this signature in database
GPG Key ID: 488D7DCFB5A430D7

View File

@ -116,7 +116,7 @@ export class DashboardComponent implements OnInit {
green = (blocksInEpoch - estimatedBlocks) / 2016 * 100;
} else {
base = blocksInEpoch / 2016 * 100;
red = (estimatedBlocks - blocksInEpoch) / 2016 * 100;
red = Math.min((estimatedBlocks - blocksInEpoch) / 2016 * 100, 100 - base);
}
return {