diff --git a/app.py b/app.py index ed77853..a98e335 100644 --- a/app.py +++ b/app.py @@ -49,6 +49,8 @@ def __init__(self): def get_db_cursor(self, connect_try=0): try: + if (self.database.is_connected() == False): + self.get_db_connection(); self.cursor = self.database.cursor(buffered=False, dictionary=True) return self.cursor except Exception as error: