Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Update app.py
Browse files
app.py
CHANGED
@@ -49,7 +49,13 @@ async def on_message(message):
|
|
49 |
break
|
50 |
|
51 |
# ask-for-help
|
52 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
53 |
title = message.embeds[0].title if message.embeds else "No Title"
|
54 |
content = message.content
|
55 |
|
|
|
49 |
break
|
50 |
|
51 |
# ask-for-help
|
52 |
+
# discord.ForumChannel.last_message_id -> The last thread ID that was created on this forum.
|
53 |
+
# when message is posted
|
54 |
+
# fetch ask-for-help channel
|
55 |
+
# if ask-for-help.last_message_id == message.id of on_message -> success
|
56 |
+
|
57 |
+
ask_for_help = await bot.fetch_channel(1019883044724822016)
|
58 |
+
if ask_for_help.last_message_id == message.channel.id:
|
59 |
title = message.embeds[0].title if message.embeds else "No Title"
|
60 |
content = message.content
|
61 |
|