From da707ade5ada3483770e87baa55dee984addf7d4 Mon Sep 17 00:00:00 2001 From: piair Date: Tue, 27 Feb 2024 01:34:51 +0100 Subject: [PATCH] moved the initialisation to Config.py --- modules/Classes/UserCredentials.py | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/modules/Classes/UserCredentials.py b/modules/Classes/UserCredentials.py index 5986bfa..1a66a71 100644 --- a/modules/Classes/UserCredentials.py +++ b/modules/Classes/UserCredentials.py @@ -3,16 +3,10 @@ from modules.Tools.logger import debug, warning class UserCredentials: - def __init__(self, config_id: int): + def __init__(self): self.data = {} self.current = 0 self.total = 0 - with open("/app/MsRewards-Reborn/user_data/configs.json", "r") as inFile: - configs = json.load(inFile) - for i in configs[str(config_id)]["accounts"]: - d = configs[str(config_id)]["accounts"][i] - self.add(d["mail"], d["pwd"], d["2fa"]) - debug(f"Initiated UserCredentials.") def add(self, username: str, password: str, tfa: str = None): debug(f"adding account with data : Username: {username}, Password: {password}, 2FA: {'None' if tfa == '' else tfa}")