mirror of
https://github.com/JonnyBro/JaBa.git
synced 2024-11-25 14:44:58 +05:00
fix error
This commit is contained in:
parent
a45840803b
commit
9fe12594cb
1 changed files with 6 additions and 1 deletions
|
@ -27,7 +27,12 @@ class Play extends Command {
|
||||||
const perms = voice.permissionsFor(this.client.user);
|
const perms = voice.permissionsFor(this.client.user);
|
||||||
if (!perms.has("CONNECT") || !perms.has("SPEAK")) return message.error("music/play:VOICE_CHANNEL_CONNECT");
|
if (!perms.has("CONNECT") || !perms.has("SPEAK")) return message.error("music/play:VOICE_CHANNEL_CONNECT");
|
||||||
|
|
||||||
await this.client.player.play(message, args.join(" "));
|
try {
|
||||||
|
await this.client.player.play(message, args.join(" "));
|
||||||
|
} catch (e) {
|
||||||
|
message.error("music/play:ERR_OCCURRED", { error: e });
|
||||||
|
console.error(e);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue