diff --git a/main.py b/main.py index f8b8053..02071b8 100644 --- a/main.py +++ b/main.py @@ -23,7 +23,7 @@ async def cmd_start(app, msg): if user_stage != 0: return except FileNotFoundError: - jsonSave(jsonLoad(f"{configGet('data', 'location')}{sep}user_default.json"), f"{configGet('data', 'location')}{sep}users{sep}{msg.from_user.id}.json") + jsonSave(jsonLoad(f"{configGet('data', 'locations')}{sep}user_default.json"), f"{configGet('data', 'locations')}{sep}users{sep}{msg.from_user.id}.json") user_stage = configGet("stage", file=str(msg.from_user.id)) configSet("telegram_id", str(msg.from_user.username), file=str(msg.from_user.id)) configSet("telegram_name", f"{msg.from_user.first_name} {msg.from_user.last_name}", file=str(msg.from_user.id)) @@ -72,7 +72,7 @@ async def confirm_yes(app, msg): await msg.reply_text(locale("application_sent", "message"), reply_markup=ReplyKeyboardRemove()) - applications = jsonLoad(f"{configGet('data', 'location')}{sep}applications.json") + applications = jsonLoad(f"{configGet('data', 'locations')}{sep}applications.json") applications[str(msg.from_user.id)] = { "approved": False, @@ -85,7 +85,7 @@ async def confirm_yes(app, msg): "application": configGet("application", file=str(msg.from_user.id)) } - jsonSave(applications, f"{configGet('data', 'location')}{sep}applications.json") + jsonSave(applications, f"{configGet('data', 'locations')}{sep}applications.json") application_content = [] i = 1 @@ -121,7 +121,7 @@ async def confirm_no(app, msg): user_stage = configGet("stage", file=str(msg.from_user.id)) if user_stage == 10: - jsonSave(jsonLoad(f"{configGet('data', 'location')}{sep}user_default.json"), f"{configGet('data', 'location')}{sep}users{sep}{msg.from_user.id}.json") + jsonSave(jsonLoad(f"{configGet('data', 'locations')}{sep}user_default.json"), f"{configGet('data', 'locations')}{sep}users{sep}{msg.from_user.id}.json") configSet("telegram_id", str(msg.from_user.username), file=str(msg.from_user.id)) configSet("telegram_name", f"{msg.from_user.first_name} {msg.from_user.last_name}", file=str(msg.from_user.id)) configSet("telegram_phone", str(msg.from_user.phone_number), file=str(msg.from_user.id))