Made the connection type configurable

This commit is contained in:
WolverinDEV 2018-09-22 15:16:28 +02:00
parent 70cee2a446
commit 5982f477fc

View file

@ -131,6 +131,7 @@ class VoiceConnection {
constructor(client) {
this.client = client;
this.type = settings.global("voice_connection_type", VoiceConnectionType.JS_ENCODE);
this.voiceRecorder = new VoiceRecorder(this);
if(this.type != VoiceConnectionType.NATIVE_ENCODE) {
this.voiceRecorder.on_data = this.handleVoiceData.bind(this);