From 178aba63dd0c1d4d4f63e33e992123969cdfb31c Mon Sep 17 00:00:00 2001 From: Andrew Date: Tue, 23 May 2023 18:21:04 -0400 Subject: [PATCH] Send empty json for no banned/cached players --- app/classes/controllers/servers_controller.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/classes/controllers/servers_controller.py b/app/classes/controllers/servers_controller.py index b7c10ed8..ca6c8d22 100644 --- a/app/classes/controllers/servers_controller.py +++ b/app/classes/controllers/servers_controller.py @@ -529,8 +529,8 @@ class ServersController(metaclass=Singleton): content = file.read() file.close() except Exception as ex: - print(ex) - return None + logger.error(ex) + return {} return json.loads(content) @@ -548,8 +548,8 @@ class ServersController(metaclass=Singleton): content = file.read() file.close() except Exception as ex: - print(ex) - return None + logger.error(ex) + return {} return json.loads(content)