Generalise exception handling
This commit is contained in:
@@ -9,7 +9,7 @@ from getpass import getpass
|
||||
|
||||
with app.app_context():
|
||||
try: users = User.query.all()
|
||||
except (SQLAlchemyError, ConnectionError) as exception: sys.exit('Database error:', exception)
|
||||
except Exception as exception: sys.exit('Database error:', exception)
|
||||
print('')
|
||||
print('This interface will allow you to override the password for an administrator account.')
|
||||
print('To exit this interface, press Ctrl + C.')
|
||||
|
Reference in New Issue
Block a user