From 43a2f99cb0775a4b41e8efc48f90831a04205685 Mon Sep 17 00:00:00 2001 From: MatteZ02 <47610069+MatteZ02@users.noreply.github.com> Date: Tue, 18 Jun 2019 10:15:56 +0300 Subject: [PATCH] Update index.js --- index.js | 1 + 1 file changed, 1 insertion(+) diff --git a/index.js b/index.js index 33ba6aab..cedccfed 100644 --- a/index.js +++ b/index.js @@ -168,6 +168,7 @@ Please provide a value to select one of the search results ranging from __1-10__ if (!msg.member.voiceChannel) return msg.channel.send(':x: You are not in a voice channel!'); if (!serverQueue) return msg.channel.send(':x: There is nothing playing.'); if (!args[1]) return msg.channel.send(`The current volume is: **${serverQueue.volume}** :speaker:`); + if (args[1] === !Number.NaN) return msg.channel.send(':x: I\'m sorry, But you neeed to enter a valid __number__. ') serverQueue.volume = args[1]; serverQueue.connection.dispatcher.setVolumeLogarithmic(args[1] / 5); return msg.channel.send(`I set the volume to: **${args[1]}** 🔊`);