Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -450,11 +450,13 @@ async def on_message(message):
|
|
450 |
context = f.read()
|
451 |
with open(f"{guild_name}.guild", "r") as f:
|
452 |
o = f.read()
|
453 |
-
|
|
|
|
|
|
|
454 |
with open(f"usrtime/{message.author}", "w") as f:
|
455 |
f.write(str(time.time()))
|
456 |
-
|
457 |
-
er = f.read()
|
458 |
if str(message.channel.id) in o.split("\n") or guild_name == "Direct" and message.author.id not in bannedUsers and time.time() - int(er) < 5:
|
459 |
with open(f"usrtime/{message.author}", "w") as f:
|
460 |
f.write(str(time.time()))
|
|
|
450 |
context = f.read()
|
451 |
with open(f"{guild_name}.guild", "r") as f:
|
452 |
o = f.read()
|
453 |
+
try:
|
454 |
+
with open(f"usrtime/{message.author}", "r") as f:
|
455 |
+
er = f.read()
|
456 |
+
except:
|
457 |
with open(f"usrtime/{message.author}", "w") as f:
|
458 |
f.write(str(time.time()))
|
459 |
+
er = time.time()
|
|
|
460 |
if str(message.channel.id) in o.split("\n") or guild_name == "Direct" and message.author.id not in bannedUsers and time.time() - int(er) < 5:
|
461 |
with open(f"usrtime/{message.author}", "w") as f:
|
462 |
f.write(str(time.time()))
|