use User#displayAvatarURL and dont encode reason

This commit is contained in:
almeidx 2021-07-28 23:40:20 +01:00
parent b4ba1daa76
commit f9e1343003
No known key found for this signature in database
GPG key ID: 8558FBFF849BD664
9 changed files with 9 additions and 12 deletions

View file

@ -51,7 +51,7 @@ export const UnbanCmd = modActionsCmd({
try {
ignoreEvent(pluginData, IgnoredEventType.Unban, user.id);
await pluginData.guild.bans.remove(user.id as Snowflake, reason != null ? encodeURIComponent(reason) : undefined);
await pluginData.guild.bans.remove(user.id as Snowflake, reason ?? undefined);
} catch {
sendErrorMessage(pluginData, msg.channel, "Failed to unban member; are you sure they're banned?");
return;