From 3e5361f9be4ad6e425f0502682a56f701ea2b6e5 Mon Sep 17 00:00:00 2001 From: Ricardo Guilherme Schmidt <3esmit@gmail.com> Date: Thu, 12 Sep 2024 02:35:02 -0300 Subject: [PATCH] fix(StakeManager): change order of call of mintBonusMP to fix intended behavior. --- contracts/StakeManager.sol | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contracts/StakeManager.sol b/contracts/StakeManager.sol index 55b5ccb..d6201d8 100644 --- a/contracts/StakeManager.sol +++ b/contracts/StakeManager.sol @@ -205,9 +205,9 @@ contract StakeManager is Ownable { account.lockUntil = block.timestamp + _secondsToLock; account.epoch = currentEpoch; //starts in current epoch account.rewardAddress = StakeVault(msg.sender).owner(); + _mintBonusMP(account, _secondsToLock, _amount); //TODO: remove this function competely account.balance = _amount; account.mpLimitEpoch = mpLimitEpoch; - _mintBonusMP(account, _secondsToLock, _amount); //update global storage totalSupplyBalance += _amount;