This commit is contained in:
loicbersier 2019-05-20 00:16:03 +02:00
parent f797af8bf8
commit 09c5057366

View file

@ -37,8 +37,8 @@ class dectalkvcCommand extends Command {
},
}).then(async (result) => {
const outputFilename = './dectalkvc.wav';
fs.writeFileSync(outputFilename, result.data)
.then(async () => {
fs.writeFile(outputFilename, result.data, async function(err) {
if (err) console.error(err);
const voiceChannel = message.member.voice.channel;
if (!voiceChannel) return message.say('Please enter a voice channel first.');
try {