refactor __init__ functions of Wallets (funding sources)
- better error messages when a conf variable is not provided - unify approaches among different source files
This commit is contained in:
@@ -21,9 +21,10 @@ class ClicheWallet(Wallet):
|
||||
"""https://github.com/fiatjaf/cliche"""
|
||||
|
||||
def __init__(self):
|
||||
if not settings.cliche_endpoint:
|
||||
raise ValueError("cannot initialize ClicheWallet: missing cliche_endpoint")
|
||||
|
||||
self.endpoint = settings.cliche_endpoint
|
||||
if not self.endpoint:
|
||||
raise Exception("cannot initialize cliche")
|
||||
|
||||
async def status(self) -> StatusResponse:
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user