liming 3 minggu lalu
induk
melakukan
9c4204f5cd
1 mengubah file dengan 1 tambahan dan 1 penghapusan
  1. 1 1
      src/stores/modules/walletStore.js

+ 1 - 1
src/stores/modules/walletStore.js

@@ -89,6 +89,7 @@ export const useWalletStore = defineStore("useWalletStore", {
         this.account = account.address;
         this.isAuthenticated = true;
         this.chainId =  `${await web3.eth.getChainId()}n`;
+        this.id = `${this.account}@${this.accountName}`
         await this.getBalance(); 
         this.addWallet()
         return {
@@ -108,7 +109,6 @@ export const useWalletStore = defineStore("useWalletStore", {
 
     // 添加钱包
     addWallet() { 
-      this.id = `${this.account}@${this.accountName}`
       const data = cloneDeep(this.$state)
       Reflect.deleteProperty(data, "walletList");
       if(this.walletList.length = 0) {