ever_daemon
ever_daemon
DIAdiscord.js - Imagine an app
Created by ever_daemon on 6/25/2022 in #djs-questions
resource.volume.setVolume returning error
I`m trying change volume in my bot, but when i try to change the volume it gives me the error
TypeError: Cannot read properties of undefined (reading 'setVolume')
TypeError: Cannot read properties of undefined (reading 'setVolume')
my code is
const volume = inter.options.get('громкость')?.value // me russian, громкость is volume


c.data.voice[inter.guildId].setVolume(volume)
// c.data.voice[inter.guildId] is object with key setVolume, setVolume contains resource.volume.setVolume
return await inter.reply('> :white_check_mark:')
const volume = inter.options.get('громкость')?.value // me russian, громкость is volume


c.data.voice[inter.guildId].setVolume(volume)
// c.data.voice[inter.guildId] is object with key setVolume, setVolume contains resource.volume.setVolume
return await inter.reply('> :white_check_mark:')
i using sodium lib libsodium-wrappers, my opus lib opusscript Thanks!
30 replies