@@ -1160,8 +1160,6 @@ public function updatePresence(Activity $activity = null, bool $idle = false, st
11601160
11611161 if (! in_array ($ activity ['type ' ], [Activity::TYPE_GAME , Activity::TYPE_STREAMING , Activity::TYPE_LISTENING , Activity::TYPE_WATCHING , Activity::TYPE_CUSTOM , Activity::TYPE_COMPETING ])) {
11621162 throw new \UnexpectedValueException ("The given activity type ( {$ activity ['type ' ]}) is invalid. " );
1163-
1164- return ;
11651163 }
11661164 }
11671165
@@ -1203,13 +1201,15 @@ public function getVoiceClient(string $guild_id): ?VoiceClient
12031201 * @param bool $mute Whether you should be mute when you join the channel.
12041202 * @param bool $deaf Whether you should be deaf when you join the channel.
12051203 * @param LoggerInterface|null $logger Voice client logger. If null, uses same logger as Discord client.
1206- * @param bool $check Whether to check for system requirements.
12071204 *
12081205 * @throws \RuntimeException
12091206 *
1207+ * @since 10.0.0 Removed argument $check that has no effect (it is always checked)
1208+ * @since 4.0.0
1209+ *
12101210 * @return PromiseInterface
12111211 */
1212- public function joinVoiceChannel (Channel $ channel , $ mute = false , $ deaf = true , ?LoggerInterface $ logger = null , bool $ check = true ): ExtendedPromiseInterface
1212+ public function joinVoiceChannel (Channel $ channel , $ mute = false , $ deaf = true , ?LoggerInterface $ logger = null ): ExtendedPromiseInterface
12131213 {
12141214 $ deferred = new Deferred ();
12151215
@@ -1241,7 +1241,7 @@ public function joinVoiceChannel(Channel $channel, $mute = false, $deaf = true,
12411241 $ this ->removeListener (Event::VOICE_STATE_UPDATE , $ voiceStateUpdate );
12421242 };
12431243
1244- $ voiceServerUpdate = function ($ vs , $ discord ) use ($ channel , &$ data , &$ voiceServerUpdate , $ deferred , $ logger, $ check ) {
1244+ $ voiceServerUpdate = function ($ vs , $ discord ) use ($ channel , &$ data , &$ voiceServerUpdate , $ deferred , $ logger ) {
12451245 if ($ vs ->guild_id != $ channel ->guild_id ) {
12461246 return ; // This voice server update isn't for our guild.
12471247 }
@@ -1274,7 +1274,7 @@ public function joinVoiceChannel(Channel $channel, $mute = false, $deaf = true,
12741274 unset($ this ->voiceClients [$ channel ->guild_id ]);
12751275 });
12761276
1277- $ vc ->start ($ check );
1277+ $ vc ->start ();
12781278
12791279 $ this ->voiceLoggers [$ channel ->guild_id ] = $ logger ;
12801280 $ this ->removeListener (Event::VOICE_SERVER_UPDATE , $ voiceServerUpdate );
0 commit comments