Commit b5b53d8b authored by Gustav Simonsson's avatar Gustav Simonsson

Fix hex conversion in --unlock and log when successful

parent 28d6b30c
...@@ -368,10 +368,11 @@ func unlockAccount(ctx *cli.Context, am *accounts.Manager, account string) (pass ...@@ -368,10 +368,11 @@ func unlockAccount(ctx *cli.Context, am *accounts.Manager, account string) (pass
if len(account) == 0 { if len(account) == 0 {
utils.Fatalf("Invalid account address '%s'", account) utils.Fatalf("Invalid account address '%s'", account)
} }
err = am.Unlock(common.StringToAddress(account), passphrase) err = am.Unlock(common.HexToAddress(account), passphrase)
if err != nil { if err != nil {
utils.Fatalf("Unlock account failed '%v'", err) utils.Fatalf("Unlock account failed '%v'", err)
} }
fmt.Printf("Account '%s' unlocked.\n", account)
return return
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment