diff --git a/plugins/plugins/core/minting/minting-info.src.js b/plugins/plugins/core/minting/minting-info.src.js index 864657a4..5ffbce55 100644 --- a/plugins/plugins/core/minting/minting-info.src.js +++ b/plugins/plugins/core/minting/minting-info.src.js @@ -525,13 +525,21 @@ class MintingInfo extends LitElement { } _levelUpDays() { - let countDays = ((this._blocksNeed() - (this.addressInfo.blocksMinted + this.addressInfo.blocksMintedAdjustment)) / this._timeCalc()).toFixed(2) - let countString = (countDays).toString() + let nextBatch = 1000 - (this.nodeInfo.height % 1000) + let countBlocks = this._blocksNeed() - (this.addressInfo.blocksMinted + this.addressInfo.blocksMintedAdjustment) + let countBlocksActual = countBlocks + 1000 + nextBatch - (countBlocks % 1000) + countBlocksActual += +countBlocksActual < 0 ? 1000 : 0 + let countDays = (countBlocksActual / this._timeCalc()).toFixed(2) + let countString = countDays.toString() return "" + countString } _levelUpBlocks() { - let countBlocksString = (this._blocksNeed() - (this.addressInfo.blocksMinted + this.addressInfo.blocksMintedAdjustment)).toString() + let nextBatch = 1000 - (this.nodeInfo.height % 1000) + let countBlocks = this._blocksNeed() - (this.addressInfo.blocksMinted + this.addressInfo.blocksMintedAdjustment) + let countBlocksActual = countBlocks + 1000 + nextBatch - (countBlocks % 1000) + countBlocksActual += +countBlocksActual < 0 ? 1000 : 0 + let countBlocksString = countBlocksActual.toString() return "" + countBlocksString }