@@ -863,10 +863,10 @@ private DynamicPropertiesStore(@Value("properties") String dbName) {
863863 }
864864
865865 try {
866- this .getAllowNewRewardEnable ();
866+ this .getAllowNewReward ();
867867 } catch (IllegalArgumentException e ) {
868- this .saveAllowNewRewardEnable (CommonParameter .getInstance ().getAllowNewRewardEnable ());
869- if (CommonParameter .getInstance ().getAllowNewRewardEnable () == 1 ) {
868+ this .saveAllowNewReward (CommonParameter .getInstance ().getAllowNewReward ());
869+ if (CommonParameter .getInstance ().getAllowNewReward () == 1 ) {
870870 this .put (NEW_REWARD_ALGORITHM_EFFECTIVE_CYCLE ,
871871 new BytesCapsule (ByteArray .fromLong (getCurrentCycleNumber ())));
872872 }
@@ -2156,7 +2156,7 @@ public void updateNextMaintenanceTime(long blockTime) {
21562156 public void addTotalNetWeight (long amount ) {
21572157 long totalNetWeight = getTotalNetWeight ();
21582158 totalNetWeight += amount ;
2159- if (allowNewRewardEnable ()) {
2159+ if (allowNewReward ()) {
21602160 totalNetWeight = Math .max (0 , totalNetWeight );
21612161 }
21622162 saveTotalNetWeight (totalNetWeight );
@@ -2166,7 +2166,7 @@ public void addTotalNetWeight(long amount) {
21662166 public void addTotalEnergyWeight (long amount ) {
21672167 long totalEnergyWeight = getTotalEnergyWeight ();
21682168 totalEnergyWeight += amount ;
2169- if (allowNewRewardEnable ()) {
2169+ if (allowNewReward ()) {
21702170 totalEnergyWeight = Math .max (0 , totalEnergyWeight );
21712171 }
21722172 saveTotalEnergyWeight (totalEnergyWeight );
@@ -2176,7 +2176,7 @@ public void addTotalEnergyWeight(long amount) {
21762176 public void addTotalTronPowerWeight (long amount ) {
21772177 long totalWeight = getTotalTronPowerWeight ();
21782178 totalWeight += amount ;
2179- if (allowNewRewardEnable ()) {
2179+ if (allowNewReward ()) {
21802180 totalWeight = Math .max (0 , totalWeight );
21812181 }
21822182 saveTotalTronPowerWeight (totalWeight );
@@ -2581,19 +2581,19 @@ public void saveMemoFeeHistory(String value) {
25812581 this .put (MEMO_FEE_HISTORY , new BytesCapsule (ByteArray .fromString (value )));
25822582 }
25832583
2584- public long getAllowNewRewardEnable () {
2584+ public long getAllowNewReward () {
25852585 return Optional .ofNullable (getUnchecked (ALLOW_NEW_REWARD ))
25862586 .map (BytesCapsule ::getData )
25872587 .map (ByteArray ::toLong )
2588- .orElseThrow (() -> new IllegalArgumentException ("not found AllowNewRewardEnable " ));
2588+ .orElseThrow (() -> new IllegalArgumentException ("not found AllowNewReward " ));
25892589 }
25902590
2591- public void saveAllowNewRewardEnable (long newReward ) {
2591+ public void saveAllowNewReward (long newReward ) {
25922592 this .put (ALLOW_NEW_REWARD , new BytesCapsule (ByteArray .fromLong (newReward )));
25932593 }
25942594
2595- public boolean allowNewRewardEnable () {
2596- return getAllowNewRewardEnable () == 1 ;
2595+ public boolean allowNewReward () {
2596+ return getAllowNewReward () == 1 ;
25972597 }
25982598
25992599 private static class DynamicResourceProperties {
0 commit comments