Files
Quetza/src/commands/stop.ts
T
2022-05-29 23:01:47 +03:00

23 lines
501 B
TypeScript

import { CommandInteraction } from "discord.js";
import Client from "../lib/Client";
import I8n from "../lib/I8n";
export async function run(client: Client, ctx: CommandInteraction) {
if (!ctx.guild || !ctx.channel) return;
const player = client.modules.music.get(ctx.guild.id, ctx.channel);
if (!player) return;
player.destroy();
await ctx.reply({ embeds: [I8n.en.destroyed()] });
}
const data = {
name: "stop",
description: "Destroys player.",
};
export { data };