mirror of
https://github.com/codex-storage/nim-ethers.git
synced 2025-02-07 09:04:02 +00:00
14 lines
290 B
Nim
14 lines
290 B
Nim
|
import ../../signer
|
||
|
|
||
|
type
|
||
|
WalletError* = object of SignerError
|
||
|
|
||
|
func raiseWalletError*(message: string) {.raises: [WalletError].}=
|
||
|
raise newException(WalletError, message)
|
||
|
|
||
|
template convertError*(body) =
|
||
|
try:
|
||
|
body
|
||
|
except CatchableError as error:
|
||
|
raiseWalletError(error.msg)
|