Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 3 additions & 9 deletions QrCodeBot-xyZ.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
from QRCodeBot import *
from datetime import datetime

now = datetime.now()
client = discord.Client()

@client.event
Expand All @@ -20,7 +19,7 @@ async def on_message(message):
return
# If the user writes $qr
if message.content == "$qr":
current_time = now.strftime("%H:%M:%S")
current_time = datetime.now().strftime("%H:%M:%S")
print('\n')
# This for loop check for all the user's DiscordID in the Database
if str(message.author.id) in ScholarsDict:
Expand All @@ -44,7 +43,7 @@ async def on_message(message):
qrcode.make(accessToken).save(qrCodePath)
# Send the QrCode the the user who asked for
await message.author.send(
"------------------------------------------------\n\n\nHello " + message.author.name + "\nHere is your new QR Code to login : ")
"---------------------------------------------------\nHello " + message.author.name + "\nHere is your new QR Code to login : ")
await message.author.send(file=discord.File(qrCodePath))
os.remove(qrCodePath)
return
Expand All @@ -54,11 +53,6 @@ async def on_message(message):
print("Current time : ", current_time)
return

print('\nThis Discord QR Code Bot has been developed by ZracheSs | xyZ')
print('Thank you for your donations!')
print('Ronin Wallet Address : ronin:a04d88fbd1cf579a83741ad6cd51748a4e2e2b6a')
print('Ethereum Wallet Address : 0x3C133521589daFa7213E5c98C74464a9577bEE01')


#print('\nThis Discord QR Code Bot has been developed by ZracheSs | xyZ')
#Run the client (This runs first)
client.run(DiscordBotToken)