diff --git a/src/commands/mod/_meta.ts b/src/commands/mod/_meta.ts
index 987a1c1..af8006c 100644
--- a/src/commands/mod/_meta.ts
+++ b/src/commands/mod/_meta.ts
@@ -3,6 +3,6 @@
 const name = "mod";
 const description = "Perform moderator actions";
 
-const subcommand = await command(name, description, `mod`)
+const subcommand = await command(name, description, `mod`);
 
 export { name, description, subcommand as command };
diff --git a/src/commands/mod/ban.ts b/src/commands/mod/ban.ts
index 7346bcc..ba60d1e 100644
--- a/src/commands/mod/ban.ts
+++ b/src/commands/mod/ban.ts
@@ -74,6 +74,7 @@
         const config = await client.database.guilds.read(interaction.guild.id);
         try {
             if (notify) {
+                if (reason) { reason = reason.split("\n").map((line) => "> " + line).join("\n") }
                 const messageData: {
                     embeds: EmojiEmbed[];
                     components: ActionRowBuilder<ButtonBuilder>[];
@@ -83,7 +84,8 @@
                             .setEmoji("PUNISH.BAN.RED")
                             .setTitle("Banned")
                             .setDescription(
-                                `You have been banned in ${interaction.guild.name}` + (reason ? ` for:\n> ${reason}` : ".")
+                                `You have been banned in ${interaction.guild.name}` +
+                                    (reason ? ` for:\n${reason}` : ".\n*No reason was provided.*")
                             )
                             .setStatus("Danger")
                     ],
diff --git a/src/commands/mod/info.ts b/src/commands/mod/info.ts
index 6b5c81e..fac87a0 100644
--- a/src/commands/mod/info.ts
+++ b/src/commands/mod/info.ts
@@ -23,6 +23,7 @@
 const command = (builder: SlashCommandSubcommandBuilder) =>
     builder
         .setName("info")
+        // .setNameLocalizations({"ru": "about", "zh-CN": "history", "zh-TW": "notes", "pt-BR": "flags"})
         .setDescription("Shows moderator information about a user")
         .addUserOption((option) =>
             option.setName("user").setDescription("The user to get information about").setRequired(true)
diff --git a/src/commands/mod/kick.ts b/src/commands/mod/kick.ts
index dd71892..88b6e14 100644
--- a/src/commands/mod/kick.ts
+++ b/src/commands/mod/kick.ts
@@ -75,6 +75,7 @@
     const config = await client.database.guilds.read(interaction.guild.id);
     try {
         if (notify) {
+            if (reason) { reason = reason.split("\n").map((line) => "> " + line).join("\n") }
             const messageData: {
                 embeds: EmojiEmbed[];
                 components: ActionRowBuilder<ButtonBuilder>[];
@@ -85,7 +86,7 @@
                         .setTitle("Kicked")
                         .setDescription(
                             `You have been kicked from ${interaction.guild.name}` +
-                                (reason ? ` for:\n> ${reason}` : ".\n*No reason was provided.*")
+                                (reason ? ` for:\n${reason}` : ".\n*No reason was provided.*")
                         )
                         .setStatus("Danger")
                 ],
diff --git a/src/commands/mod/mute.ts b/src/commands/mod/mute.ts
index 05a9ec2..d68272b 100644
--- a/src/commands/mod/mute.ts
+++ b/src/commands/mod/mute.ts
@@ -13,6 +13,7 @@
 const command = (builder: SlashCommandSubcommandBuilder) =>
     builder
         .setName("mute")
+        // .setNameLocalizations({"ru": "silence"})
         .setDescription("Mutes a member, stopping them from talking in the server")
         .addUserOption((option) => option.setName("user").setDescription("The user to mute").setRequired(true))
         .addIntegerOption((option) =>
@@ -234,6 +235,7 @@
     let dmMessage;
     try {
         if (notify) {
+            if (reason) { reason = reason.split("\n").map((line) => "> " + line).join("\n") }
             const messageData: {
                 embeds: EmojiEmbed[];
                 components: ActionRowBuilder<ButtonBuilder>[];
@@ -244,7 +246,7 @@
                         .setTitle("Muted")
                         .setDescription(
                             `You have been muted in ${interaction.guild.name}` +
-                                (reason ? ` for:\n> ${reason}` : ".\n*No reason was provided*") + "\n\n" +
+                                (reason ? ` for:\n${reason}` : ".\n*No reason was provided*") + "\n\n" +
                             `You will be unmuted at: <t:${Math.round(new Date().getTime() / 1000) + muteTime}:D> at ` +
                             `<t:${Math.round(new Date().getTime() / 1000) + muteTime}:T> (<t:${Math.round(new Date().getTime() / 1000) + muteTime
                             }:R>)` + "\n\n" +
diff --git a/src/commands/mod/nick.ts b/src/commands/mod/nick.ts
index 0975375..81935a2 100644
--- a/src/commands/mod/nick.ts
+++ b/src/commands/mod/nick.ts
@@ -1,4 +1,4 @@
-import { CommandInteraction, GuildMember } from "discord.js";
+import type { CommandInteraction, GuildMember } from "discord.js";
 import type { SlashCommandSubcommandBuilder } from "@discordjs/builders";
 import confirmationMessage from "../../utils/confirmationMessage.js";
 import EmojiEmbed from "../../utils/generateEmojiEmbed.js";
@@ -8,6 +8,7 @@
 
 const command = (builder: SlashCommandSubcommandBuilder) => builder
     .setName("nick")
+    // .setNameLocalizations({"ru": "name", "zh-CN": "nickname"})
     .setDescription("Changes a users nickname")
     .addUserOption((option) => option.setName("user").setDescription("The user to change").setRequired(true))
     .addStringOption((option) =>
diff --git a/src/commands/mod/purge.ts b/src/commands/mod/purge.ts
index 6087890..3020eb8 100644
--- a/src/commands/mod/purge.ts
+++ b/src/commands/mod/purge.ts
@@ -29,11 +29,7 @@
     if (!interaction.guild) return;
     const user = (interaction.options.getMember("user") as GuildMember | null);
     const channel = interaction.channel as GuildChannel;
-    if (
-        !["GUILD_TEXT", "GUILD_NEWS", "GUILD_NEWS_THREAD", "GUILD_PUBLIC_THREAD", "GUILD_PRIVATE_THREAD"].includes(
-            channel.type.toString()
-        )
-    ) {
+    if (channel.isTextBased()) {
         return await interaction.reply({
             embeds: [
                 new EmojiEmbed()
diff --git a/src/commands/mod/warn.ts b/src/commands/mod/warn.ts
index 390baa5..d920bb0 100644
--- a/src/commands/mod/warn.ts
+++ b/src/commands/mod/warn.ts
@@ -84,6 +84,7 @@
     const config = await client.database.guilds.read(interaction.guild.id);
     try {
         if (notify) {
+            if (reason) { reason = reason.split("\n").map((line) => "> " + line).join("\n") }
             const messageData: {
                 embeds: EmojiEmbed[];
                 components: ActionRowBuilder<ButtonBuilder>[];
@@ -94,7 +95,7 @@
                         .setTitle("Warned")
                         .setDescription(
                             `You have been warned in ${interaction.guild.name}` +
-                                (reason ? ` for:\n> ${reason}` : ".\n*No reason was provided*") +
+                                (reason ? ` for:\n${reason}` : ".\n*No reason was provided*") +
                                 "\n\n" +
                                 (createAppealTicket
                                     ? `You can appeal this in the ticket created in <#${confirmation.components!["appeal"]!.response}>`
