Update error message

This commit is contained in:
Dimitris Zlatanidis 2024-03-15 22:04:49 +02:00
parent 82e50198ef
commit 0d036c5d08

View file

@ -202,10 +202,10 @@ class Utilities(Configs):
Returns: Returns:
Dictionary with data. Dictionary with data.
""" """
json_data: dict = {}
try: try:
json_data: dict = json.loads(file.read_text(encoding='utf-8')) json_data: dict = json.loads(file.read_text(encoding='utf-8'))
except FileNotFoundError: except FileNotFoundError:
print(f'\n{self.prog_name}: Error file {file} not found.\n') print()
self.errors.raise_error_message(f'{file} not found.', exit_status=1)
raise SystemExit(1) raise SystemExit(1)
return json_data return json_data