Skip to content

Commit

Permalink
update Morelo
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaolin1579 committed Sep 17, 2024
1 parent c3d54e9 commit 938c1d1
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public static class MoreloConstants
{
public const decimal MoreloReserveRewardInitial = 5.555m; // MiningReward = BlockReward - ReserveReward
public const decimal MoreloStaticTransactionFeeReserve = 1.0m; // Deduct static reserve for tx fees

public const int MoreloMinBlockConfirmations = 18;
}

public static class EquilibriaConstants
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -410,8 +410,9 @@ public async Task<Block[]> ClassifyBlocksAsync(IMiningPool pool, Block[] blocks,

var blockHeader = rpcResult.Response.BlockHeader;

// update progress
block.ConfirmationProgress = Math.Min(1.0d, (double) blockHeader.Depth / CryptonoteConstants.PayoutMinBlockConfirmations);
// update progressint
int PayoutMinBlockConfirmations = (coin.Symbol == "MRL") ? MoreloConstants.MoreloMinBlockConfirmations : CryptonoteConstants.PayoutMinBlockConfirmations;
block.ConfirmationProgress = Math.Min(1.0d, (double) blockHeader.Depth / PayoutMinBlockConfirmations);
result.Add(block);

messageBus.NotifyBlockConfirmationProgress(poolConfig.Id, block, coin);
Expand All @@ -427,7 +428,7 @@ public async Task<Block[]> ClassifyBlocksAsync(IMiningPool pool, Block[] blocks,
}

// matured and spendable?
if(blockHeader.Depth >= CryptonoteConstants.PayoutMinBlockConfirmations)
if(blockHeader.Depth >= PayoutMinBlockConfirmations)
{
block.Status = BlockStatus.Confirmed;
block.ConfirmationProgress = 1;
Expand Down

0 comments on commit 938c1d1

Please sign in to comment.