From 6164b9d27ef3de75b4b307421eb5f7ce5799ca20 Mon Sep 17 00:00:00 2001 From: fiatjaf Date: Wed, 24 Mar 2021 09:49:43 -0300 Subject: [PATCH] exit the app when we cannot connect to a backend. --- lnbits/app.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lnbits/app.py b/lnbits/app.py index 641deed0..40a9723f 100644 --- a/lnbits/app.py +++ b/lnbits/app.py @@ -1,3 +1,4 @@ +import sys import importlib import warnings @@ -61,6 +62,8 @@ def check_funding_source(app: QuartTrio) -> None: f" × The backend for {WALLET.__class__.__name__} isn't working properly: '{error_message}'", RuntimeWarning, ) + + sys.exit(4) else: print( f" ✔️ {WALLET.__class__.__name__} seems to be connected and with a balance of {balance} msat."