feat(VoiceConnection): add .voice

This commit is contained in:
Amish Shah
2019-04-29 19:13:41 +01:00
parent 2666a9d6db
commit ce1e3d2084

View File

@@ -166,6 +166,14 @@ class VoiceConnection extends EventEmitter {
}); });
} }
/**
* The voice state of this connection
* @type {VoiceState}
*/
get voice() {
return this.channel.guild.voiceStates.get(this.client.user.id);
}
/** /**
* Sends a request to the main gateway to join a voice channel. * Sends a request to the main gateway to join a voice channel.
* @param {Object} [options] The options to provide * @param {Object} [options] The options to provide