fix(@desktop/wallet): adding derived wallet account fixed
An issue with adding wallet account was happening only for a new user, the reason for that was incorrectly set keystore path and keystore file couldn't be found on the statusgo side because of that.
This commit is contained in:
parent
6237d3c7c1
commit
3da62c9092
|
@ -345,6 +345,7 @@ proc setupAccount*(self: Service, accountId, password, displayName: string): str
|
|||
try:
|
||||
let installationId = $genUUID()
|
||||
var accountDataJson = self.getAccountDataForAccountId(accountId, displayName)
|
||||
self.setKeyStoreDir(accountDataJson{"key-uid"}.getStr) # must be called before `getDefaultNodeConfig`
|
||||
let subaccountDataJson = self.getSubaccountDataForAccountId(accountId, displayName)
|
||||
var settingsJson = self.getAccountSettings(accountId, installationId, displayName)
|
||||
let nodeConfigJson = self.getDefaultNodeConfig(installationId)
|
||||
|
@ -355,7 +356,6 @@ proc setupAccount*(self: Service, accountId, password, displayName: string): str
|
|||
error "error: ", procName="setupAccount", errDesription = description
|
||||
return description
|
||||
|
||||
self.setKeyStoreDir(accountDataJson{"key-uid"}.getStr)
|
||||
let hashedPassword = hashString(password)
|
||||
discard self.storeAccount(accountId, hashedPassword)
|
||||
discard self.storeDerivedAccounts(accountId, hashedPassword, PATHS)
|
||||
|
|
|
@ -96,10 +96,10 @@ StatusModal {
|
|||
&& !!advancedSelection.expandableItem.mnemonicText) {
|
||||
RootStore.getDerivedAddressListForMnemonic(advancedSelection.expandableItem.mnemonicText,
|
||||
advancedSelection.expandableItem.path, numOfItems, pageNumber)
|
||||
} else if(!!advancedSelection.expandableItem.path && !!advancedSelection.expandableItem.derivedFromAddress
|
||||
} else if(!!d.selectedPath && !!d.selectedAccountDerivedFromAddress
|
||||
&& (d.password.length > 0)) {
|
||||
RootStore.getDerivedAddressList(d.password, advancedSelection.expandableItem.derivedFromAddress,
|
||||
advancedSelection.expandableItem.path, numOfItems, pageNumber)
|
||||
RootStore.getDerivedAddressList(d.password, d.selectedAccountDerivedFromAddress,
|
||||
d.selectedPath, numOfItems, pageNumber)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue