From fa878bb92a9314f8e5127a76af9d1e21651032bc Mon Sep 17 00:00:00 2001 From: depreciate Date: Sat, 5 Jan 2019 06:38:43 +1030 Subject: [PATCH] logs --- ripple/userUtils.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ripple/userUtils.py b/ripple/userUtils.py index 489ff97..500f65d 100644 --- a/ripple/userUtils.py +++ b/ripple/userUtils.py @@ -10,7 +10,10 @@ from common.log import logUtils as log from common.ripple import passwordUtils, scoreUtils from objects import glob - +def logUserLog(log,fileMd5,userID, gameMode): + glob.db.execute("INSERT INTO users_logs (user, log, time, game_mode, beatmap_md5) VALUES (%s, %s, %s, %s, %s)",[userID, log, int(time.time()), gameMode, fileMd5]) + return True + def getBeatmapTime(beatmapID): p = 0 r = requests.get("http://cg.mxr.lol/api/b/{}".format(beatmapID)).text