diff --git a/dislocker.py b/dislocker.py index 7adde0d..4add94a 100644 --- a/dislocker.py +++ b/dislocker.py @@ -30,6 +30,7 @@ class Bot(discord.Client): #パスワード生成、ハッシュ化 password = self.password_generate(4) password_hash = self.hash_genarate(password) + print("パスワード生成完了") #メンバーリストと送信者を照合 cursor = self.db.cursor() cursor.execute("SELECT * FROM club_member WHERE discord_userid = %s", (discord_user_id,)) @@ -39,9 +40,11 @@ class Bot(discord.Client): result = {"result": "user_data_not_found"} #ユーザーデータが見つかった場合(登録済みの場合) else: + print("ユーザーデータが見つかった") cursor.execute("SELECT * FROM pc_usage_history WHERE member_id=%s ORDER BY id DESC LIMIT 1", (user_record[0][0],)) pc_usage_history_record = cursor.fetchall() if pc_usage_history_record: + print("使用したことがあります") if pc_usage_history_record[0][5] == None: result = {"result": "pc_already_in_use_by_you", "pc_number": str(pc_usage_history_record[0][2]), "device_number": str(pc_usage_history_record[0][3]), "start_time": str(pc_usage_history_record[0][4]), "detail": str(pc_usage_history_record[0][6])} else: