From 9cee07f702695491d7dfae118362293fffabc8c3 Mon Sep 17 00:00:00 2001 From: RGBCube <78925721+RGBCube@users.noreply.github.com> Date: Thu, 27 Jan 2022 18:59:45 +0300 Subject: [PATCH] Update json_wrapper.py --- json_wrapper.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/json_wrapper.py b/json_wrapper.py index 8163312..be0a1c2 100644 --- a/json_wrapper.py +++ b/json_wrapper.py @@ -33,7 +33,7 @@ class _JsonUtils: with open(self.json_path, mode="r") as json_file: data = json.load(json_file) - except (FileNotFoundError, ValueError): + except (FileNotFoundError, JSONDecodeError): with open(self.json_path, mode="w") as json_file: json.dump({}, json_file) return