We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4c71d92 commit aec1528Copy full SHA for aec1528
Tasks/PunishmentTasks.cs
@@ -122,7 +122,8 @@ public static async Task<bool> CleanUpPunishmentMessagesAsync()
122
try
123
{
124
var contextMessage = await DiscordHelpers.GetMessageFromReferenceAsync(ban.ContextMessageReference);
125
- await contextMessage.DeleteAsync();
+ if (contextMessage is not null)
126
+ await contextMessage.DeleteAsync();
127
Program.redis.HashDelete("compromisedAccountBans", ban.MemberId);
128
success = true;
129
}
0 commit comments