This commit is contained in:
piair 2022-09-30 14:59:54 +02:00
parent 994af56880
commit 43e970a1aa
2 changed files with 2 additions and 2 deletions

2
V4.py
View File

@ -886,7 +886,7 @@ def LogPoint(account="unknown"): # log des points sur discord
webhookSuccess.send(f"{account} actuellement à {str(points)} points") webhookSuccess.send(f"{account} actuellement à {str(points)} points")
if sql_enabled : if sql_enabled :
add_to_database(account, points) add_to_database(account, points, sql_host, sql_usr, sql_pwd, sql_database)
def Fidelite(): def Fidelite():

View File

@ -32,7 +32,7 @@ def get_row(compte, points, mycursor, same_points = True): #return if there is a
return(len(myresult) == 1) return(len(myresult) == 1)
def add_to_database(compte, points): def add_to_database(compte, points, sql_host,sql_usr,sql_pwd,sql_database ):
mydb = mysql.connector.connect( mydb = mysql.connector.connect(
host=sql_host, host=sql_host,
user=sql_usr, user=sql_usr,