test
This commit is contained in:
parent
0bc7686733
commit
578881e3dd
1 changed files with 1 additions and 4 deletions
|
@ -27,9 +27,6 @@ class TtsvcCommand extends Command {
|
||||||
async exec(message, args) {
|
async exec(message, args) {
|
||||||
let text = args.text;
|
let text = args.text;
|
||||||
|
|
||||||
const { voiceChannel } = message.member;
|
|
||||||
|
|
||||||
|
|
||||||
// Construct the request
|
// Construct the request
|
||||||
const request = {
|
const request = {
|
||||||
input: { text: text },
|
input: { text: text },
|
||||||
|
@ -59,7 +56,7 @@ class TtsvcCommand extends Command {
|
||||||
// If not in voice channel ask user to join
|
// If not in voice channel ask user to join
|
||||||
|
|
||||||
if (message.member.voice.channel) {
|
if (message.member.voice.channel) {
|
||||||
const connection = await message.member.voice.channel.join();
|
const voiceChannel = message.member.voice.channel.join();
|
||||||
if (text == 'stop') {
|
if (text == 'stop') {
|
||||||
voiceChannel.leave();
|
voiceChannel.leave();
|
||||||
message.channel.send('I leaved the channel');
|
message.channel.send('I leaved the channel');
|
||||||
|
|
Loading…
Reference in a new issue