Ignore bot DMs
This commit is contained in:
parent
06c94e370a
commit
72c9415da9
2 changed files with 3 additions and 1 deletions
|
@ -23,6 +23,7 @@ namespace Noikoio.RegexBot.Module.DMLogger
|
|||
private async Task Client_MessageReceived(SocketMessage arg)
|
||||
{
|
||||
if (!(arg.Channel is IDMChannel)) return;
|
||||
if (arg.Author.IsBot) return;
|
||||
|
||||
await ProcessMessage(arg, false);
|
||||
}
|
||||
|
@ -30,6 +31,7 @@ namespace Noikoio.RegexBot.Module.DMLogger
|
|||
private async Task Client_MessageUpdated(Cacheable<IMessage, ulong> arg1, SocketMessage arg2, ISocketMessageChannel arg3)
|
||||
{
|
||||
if (!(arg2.Channel is IDMChannel)) return;
|
||||
if (arg2.Author.IsBot) return;
|
||||
|
||||
await ProcessMessage(arg2, true);
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>netcoreapp2.0</TargetFramework>
|
||||
<RootNamespace>Noikoio.RegexBot</RootNamespace>
|
||||
<AssemblyVersion>2.3.1.0</AssemblyVersion>
|
||||
<AssemblyVersion>2.3.2.0</AssemblyVersion>
|
||||
<Description>Highly configurable Discord moderation bot</Description>
|
||||
<Authors>Noikoio</Authors>
|
||||
<Company />
|
||||
|
|
Loading…
Reference in a new issue