diff options
Diffstat (limited to 'accounts/errors.go')
-rw-r--r-- | accounts/errors.go | 29 |
1 files changed, 28 insertions, 1 deletions
diff --git a/accounts/errors.go b/accounts/errors.go index d6f578b52..9ecc1eafd 100644 --- a/accounts/errors.go +++ b/accounts/errors.go @@ -16,7 +16,34 @@ package accounts -import "fmt" +import ( + "errors" + "fmt" +) + +// ErrUnknownAccount is returned for any requested operation for which no backend +// provides the specified account. +var ErrUnknownAccount = errors.New("unknown account") + +// ErrUnknownWallet is returned for any requested operation for which no backend +// provides the specified wallet. +var ErrUnknownWallet = errors.New("unknown wallet") + +// ErrNotSupported is returned when an operation is requested from an account +// backend that it does not support. +var ErrNotSupported = errors.New("not supported") + +// ErrInvalidPassphrase is returned when a decryption operation receives a bad +// passphrase. +var ErrInvalidPassphrase = errors.New("invalid passphrase") + +// ErrWalletAlreadyOpen is returned if a wallet is attempted to be opened the +// secodn time. +var ErrWalletAlreadyOpen = errors.New("wallet already open") + +// ErrWalletClosed is returned if a wallet is attempted to be opened the +// secodn time. +var ErrWalletClosed = errors.New("wallet closed") // AuthNeededError is returned by backends for signing requests where the user // is required to provide further authentication before signing can succeed. |