Added mod_chat_sanitizer for messages deletion

This commit is contained in:
Nikita Tyukalov, ASUS, Linux
2025-11-25 04:55:47 +03:00
parent 6975b817d0
commit 27bfc18c1f
6 changed files with 753 additions and 14 deletions

View File

@@ -1,6 +1,7 @@
''' Config reader '''
import json
import utils
def read_config(path: str) -> dict | None:
''' Read config '''
@@ -30,11 +31,10 @@ def read_config(path: str) -> dict | None:
required_fields = {
'login': [str]
}
optional_fields = {
'mod_basic': ([bool], True),
'mod_eternal_online': ([bool], False),
'mod_video_downloader': ([bool], False)
}
optional_fields = {}
for mod_name in utils.get_all_mods():
optional_fields[mod_name] = ([bool], False)
optional_fields['mod_basic'] = ([bool], True)
try:
j = None
with open(path, 'r') as f: