cmd/clef: fix error string format

This commit is contained in:
trillom8 2024-05-26 16:28:54 +09:00
parent 3d852a4d37
commit a57c527114

View file

@ -552,7 +552,7 @@ func listWallets(c *cli.Context) error {
// accountImport imports a raw hexadecimal private key via CLI. // accountImport imports a raw hexadecimal private key via CLI.
func accountImport(c *cli.Context) error { func accountImport(c *cli.Context) error {
if c.Args().Len() != 1 { if c.Args().Len() != 1 {
return errors.New("<keyfile> must be given as first argument.") return errors.New("<keyfile> must be given as first argument")
} }
internalApi, ui, err := initInternalApi(c) internalApi, ui, err := initInternalApi(c)
if err != nil { if err != nil {
@ -583,7 +583,7 @@ func accountImport(c *cli.Context) error {
} }
if first != second { if first != second {
//lint:ignore ST1005 This is a message for the user //lint:ignore ST1005 This is a message for the user
return errors.New("Passwords do not match") return errors.New("passwords do not match")
} }
acc, err := internalApi.ImportRawKey(hex.EncodeToString(crypto.FromECDSA(pKey)), first) acc, err := internalApi.ImportRawKey(hex.EncodeToString(crypto.FromECDSA(pKey)), first)
if err != nil { if err != nil {