File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
chainbase/src/main/java/org/tron/core/store Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change 2424@ Component
2525public class AccountStore extends TronStoreWithRevoking <AccountCapsule > {
2626
27+ private static String ACCOUNT_BLACKHOLE = "Blackhole" ;
28+
2729 private static Map <String , byte []> assertsAddress = new HashMap <>(); // key = name , value = address
2830
2931 @ Autowired
@@ -51,7 +53,7 @@ public static void setAccount(com.typesafe.config.Config config) {
5153 byte [] address = Commons .decodeFromBase58Check (obj .get ("address" ).unwrapped ().toString ());
5254 assertsAddress .put (accountName , address );
5355 }
54- if (assertsAddress .get ("Blackhole" ) == null ) {
56+ if (assertsAddress .get (ACCOUNT_BLACKHOLE ) == null ) {
5557 throw new TronError ("Account[Blackhole] is not configured." , TronError .ErrCode .GENESIS_BLOCK_INIT );
5658 }
5759 }
@@ -113,12 +115,12 @@ public AccountCapsule getSun() {
113115 * Min TRX account.
114116 */
115117 public AccountCapsule getBlackhole () {
116- return getUnchecked (assertsAddress .get ("Blackhole" ));
118+ return getUnchecked (assertsAddress .get (ACCOUNT_BLACKHOLE ));
117119 }
118120
119121
120122 public byte [] getBlackholeAddress () {
121- return assertsAddress .get ("Blackhole" );
123+ return assertsAddress .get (ACCOUNT_BLACKHOLE );
122124 }
123125
124126 /**
You can’t perform that action at this time.
0 commit comments