From ae2b2149049531215b8b1469af212374fd253bd5 Mon Sep 17 00:00:00 2001 From: StNicolay Date: Mon, 31 Oct 2022 21:09:12 +0300 Subject: [PATCH] Fixed an error of getting wrong account I'm now quite shure how it worked before --- src/database/get.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/database/get.py b/src/database/get.py index 2884b91..b51e04e 100644 --- a/src/database/get.py +++ b/src/database/get.py @@ -29,7 +29,7 @@ def get_account_info( ) -> tuple[bytes, bytes, bytes]: """Gets account info. Returns tuple of salt, login and password""" statement = sqlmodel.select(models.Account).where( - models.Account.user_id == user_id and models.Account.name == name + models.Account.user_id == user_id, models.Account.name == name ) with sqlmodel.Session(engine) as session: result = session.exec(statement).first()