Перевод на класс user_ и проверка ников.

This commit is contained in:
Your Name
2024-04-20 11:55:10 +03:00
parent a37d442cda
commit 247457937d
2 changed files with 182 additions and 88 deletions
+4 -2
View File
@@ -2,11 +2,13 @@ import os
import json
if not os.path.exists('db.json'):
db = {}
db = {"token": "None"}
js = json.dumps(db, indent=2)
with open("db.json", "w") as outfile:
outfile.write(js)
print('Created new db.json')
print('Создана БД')
print('Введите токен db.json')
exit()
def read_db(file = 'db.json'):