Skip to content

Commit

Permalink
Interesting proposal test
Browse files Browse the repository at this point in the history
  • Loading branch information
hhvrc committed Sep 16, 2024
1 parent 0bdcf39 commit 7130fd9
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions DiscordBot/MessageHandler/MessageHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,14 @@ public async Task HandleMessageAsync(SocketMessage message)

bool isInBotChannel = message.Channel.Id == 1114123393567047730;

// Check if message starts with the lightning bolt emoji and mentions a user
if (message.Content.StartsWith(":zap:") && message.MentionedUsers.Count > 0)
{
// Checkmark the message
await message.AddReactionAsync(new Emoji(""));
return;
}

// Check if the message contains a swear word
if (ProfanityDetector.TryGetProfanityWeight(message.Content, out int count, out float weight))
{
Expand Down

0 comments on commit 7130fd9

Please sign in to comment.