Fix null exception

This commit is contained in:
Noikoio 2020-05-06 17:56:11 -07:00
parent 67b89f6bc2
commit 20995124ca

View file

@ -157,6 +157,7 @@ namespace Noikoio.RegexBot.Module.AutoMod
string msgcontent;
if (MatchEmbed) msgcontent = SerializeEmbed(m.Embeds);
else msgcontent = m.Content;
if (msgcontent == null) return false;
// Min/max length check
if (_msgMinLength != -1 && msgcontent.Length <= _msgMinLength) return false;