Use provided datadir

This commit is contained in:
Andrea Maria Piana 2023-05-29 16:51:23 +01:00 committed by Jakub Sokołowski
parent b701005f3b
commit 46399d1905
No known key found for this signature in database
GPG Key ID: FE65CD384D5BF7B4
1 changed files with 2 additions and 2 deletions

View File

@ -324,9 +324,9 @@ func defaultNodeConfig(installationID string) (*params.NodeConfig, error) {
} }
func ImportAccount(seedPhrase string, backend *api.GethStatusBackend) error { func ImportAccount(seedPhrase string, backend *api.GethStatusBackend) error {
backend.UpdateRootDataDir("./tmp") backend.UpdateRootDataDir(*dataDir)
manager := backend.AccountManager() manager := backend.AccountManager()
if err := manager.InitKeystore("./tmp"); err != nil { if err := manager.InitKeystore(*dataDir); err != nil {
return err return err
} }
err := backend.OpenAccounts() err := backend.OpenAccounts()