summaryrefslogtreecommitdiff
path: root/server/src/utils/Utils.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/src/utils/Utils.ts')
-rw-r--r--server/src/utils/Utils.ts12
1 files changed, 12 insertions, 0 deletions
diff --git a/server/src/utils/Utils.ts b/server/src/utils/Utils.ts
index 454840e..e7972c2 100644
--- a/server/src/utils/Utils.ts
+++ b/server/src/utils/Utils.ts
@@ -2,4 +2,16 @@ export default class Util {
static shorten(text: string, maxLen = 2000) {
return text.length > maxLen ? `${text.substr(0, maxLen - 3)}...` : text;
}
+
+ static canModifyQueue(member) {
+ const { channel } = member.voice;
+ const botChannel = member.guild.me.voice.channel;
+
+ if (channel !== botChannel) {
+ member.send('You need to join the voice channel first!'); // error
+ return false;
+ }
+
+ return false;
+ }
} \ No newline at end of file