Skip to content

Commit a1a8eab

Browse files
committed
SFC can change offlinePenaltyThreshold
1 parent fb5cbb9 commit a1a8eab

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

contracts/sfc/Staker.sol

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -873,14 +873,18 @@ contract Stakers is Ownable, StakersConstants, Version {
873873
emit PartialWithdrawnByRequest(auth, receiver, stakerID, wrID, delegation, penalty);
874874
}
875875

876-
function updateGasPowerAllocationRate(uint256 short, uint256 long) onlyOwner external {
876+
function _updateGasPowerAllocationRate(uint256 short, uint256 long) onlyOwner external {
877877
emit UpdatedGasPowerAllocationRate(short, long);
878878
}
879879

880-
function updateBaseRewardPerSec(uint256 value) onlyOwner external {
880+
function _updateBaseRewardPerSec(uint256 value) onlyOwner external {
881881
emit UpdatedBaseRewardPerSec(value);
882882
}
883883

884+
function _updateOfflinePenaltyThreshold(uint256 blocksNum, uint256 period) onlyOwner external {
885+
emit UpdatedOfflinePenaltyThreshold(blocksNum, period);
886+
}
887+
884888
function startLockedUp(uint256 epochNum) onlyOwner external {
885889
require(epochNum > currentSealedEpoch, "can't start in the past");
886890
require(firstLockedUpEpoch == 0 || firstLockedUpEpoch > currentSealedEpoch, "feature was started");

contracts/sfc/StakerConstants.sol

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,4 +122,5 @@ contract StakersConstants {
122122

123123
event UpdatedBaseRewardPerSec(uint256 value);
124124
event UpdatedGasPowerAllocationRate(uint256 short, uint256 long);
125+
event UpdatedOfflinePenaltyThreshold(uint256 blocksNum, uint256 period);
125126
}

0 commit comments

Comments
 (0)