1
0
Fork 1
mirror of https://github.com/TeamOctolings/Octobot.git synced 2025-05-20 20:50:57 +03:00

Remove timeout from user if it exists, but there is a mute role configured

This commit is contained in:
l1ttleO 2022-07-15 18:32:54 +05:00
parent 552ebdd4e0
commit a06376443f
Signed by: Octol1ttle
GPG key ID: B77C34313AEE1FFF
2 changed files with 3 additions and 7 deletions

View file

@ -57,9 +57,8 @@ public class EventHandler {
}
private static async Task MessageReceivedEvent(SocketMessage messageParam) {
if (messageParam is not SocketUserMessage message) return;
if (messageParam is not SocketUserMessage { Author: SocketGuildUser user } message) return;
var user = (SocketGuildUser)message.Author;
var guild = user.Guild;
var guildConfig = Boyfriend.GetGuildConfig(guild.Id);