From 6e1c83ec6ef7f3133b615e62ec4c64312104a411 Mon Sep 17 00:00:00 2001 From: Philip Sargent Date: Sun, 11 Aug 2024 17:02:35 +0300 Subject: [PATCH] Catch exception when database reset ongoing --- core/utils.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/core/utils.py b/core/utils.py index f49ef26..624cfff 100644 --- a/core/utils.py +++ b/core/utils.py @@ -51,7 +51,10 @@ class DatabaseResetOngoing(Exception): """Exception class for errors while the server is reimporting everything""" def __init__(self, message): - self.message = message + if message: + self.message = message + else: + self.message = f"Expo Database re-import ongoing on server.\nPlease wait 7 minutes.\n If still not working, contact a nerd." def __str__(self): return f"DatabaseResetOngoing: {self.message}"