From c99b4dbd4a910079ac230cdd631cfc93dd26967b Mon Sep 17 00:00:00 2001 From: Brett Date: Tue, 8 Jul 2025 23:11:44 -0400 Subject: [PATCH] check --- news/main.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/news/main.py b/news/main.py index 2ce840b..0ba2772 100644 --- a/news/main.py +++ b/news/main.py @@ -328,6 +328,10 @@ async def on_message(message: discord.Message) -> None: if message.author == bot.user: return + if message.author.id != 199680010267656192: + await message.channel.send("Only authorized users are allowed to use this bot.") + return + if message.content.startswith("!"): if message.content == "!process": asyncio.create_task(process_articles(message)) @@ -352,10 +356,6 @@ async def on_message(message: discord.Message) -> None: if not (is_dm or is_mention): return - if is_dm and message.author.id != 199680010267656192: - await message.channel.send("Only authorized users are allowed to use this bot.") - return - url = extract_first_url(message.content) if not url: await message.channel.send("Please send me a link to a news article.")