mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-18 12:33:30 +01:00
docs(VoiceState): #setRequestToSpeak and #setSuppressed returns a Promise instead of void (#5558)
This commit is contained in:
@@ -218,6 +218,7 @@ class VoiceState extends Base {
|
|||||||
* @example
|
* @example
|
||||||
* // Making the client cancel a request to speak
|
* // Making the client cancel a request to speak
|
||||||
* guild.me.voice.setRequestToSpeak(false);
|
* guild.me.voice.setRequestToSpeak(false);
|
||||||
|
* @returns {Promise<void>}
|
||||||
*/
|
*/
|
||||||
async setRequestToSpeak(request) {
|
async setRequestToSpeak(request) {
|
||||||
const channel = this.channel;
|
const channel = this.channel;
|
||||||
@@ -248,6 +249,7 @@ class VoiceState extends Base {
|
|||||||
* @example
|
* @example
|
||||||
* // Moving another user to the audience, or cancelling their invite to speak
|
* // Moving another user to the audience, or cancelling their invite to speak
|
||||||
* voiceState.setSuppressed(true);
|
* voiceState.setSuppressed(true);
|
||||||
|
* @returns {Promise<void>}
|
||||||
*/
|
*/
|
||||||
async setSuppressed(suppressed) {
|
async setSuppressed(suppressed) {
|
||||||
if (typeof suppressed !== 'boolean') throw new TypeError('VOICE_STATE_INVALID_TYPE', 'suppressed');
|
if (typeof suppressed !== 'boolean') throw new TypeError('VOICE_STATE_INVALID_TYPE', 'suppressed');
|
||||||
|
|||||||
Reference in New Issue
Block a user