Completed add_account function

This commit is contained in:
StNicolay 2022-10-05 14:47:34 +03:00
parent 7cfb97199f
commit 6546fc0401

View File

@ -14,10 +14,15 @@ def add_master_pass(
def add_account(
id: int,
salt: bytes,
acc_name: str,
salt: bytes,
enc_login: bytes,
enc_passwd: bytes,
con: mariadb.Connection,
) -> bool:
...
cursor = con.cursor()
cursor.execute(
"INSERT INTO accounts (user_id, acc_name, salt, enc_login, enc_pass) VALUES (?, ?, ?, ?, ?, ?)",
[id, acc_name, salt, enc_login, enc_passwd],
)
cursor.close()