-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathresume.js
25 lines (23 loc) · 858 Bytes
/
resume.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
const { MessageEmbed } = require("discord.js");
const sendError = require("../util/error")
module.exports = {
info: {
name: "resume",
description: "To resume the paused music",
usage: "",
aliases: [],
},
run: async function (client, message, args) {
const serverQueue = message.client.queue.get(message.guild.id);
if (serverQueue && !serverQueue.playing) {
serverQueue.playing = true;
serverQueue.connection.dispatcher.resume();
let xd = new MessageEmbed()
.setDescription("▶ Resumed the music for you!")
.setColor("YELLOW")
.setAuthor("Music has been Resumed!", "https://raw.githubusercontent.com/SudhanPlayz/Discord-MusicBot/master/assets/Music.gif")
return message.channel.send(xd);
}
return sendError("There is nothing playing in this server.", message.channel);
},
};