From 984a39cafade28e1245772388d3392284b6ff1ae Mon Sep 17 00:00:00 2001 From: Julius de Jeu Date: Sat, 20 Oct 2018 22:10:44 +0200 Subject: [PATCH] fix music channel --- src/main/kotlin/nl/voidcorp/dbot/music/TrackScheduler.kt | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/main/kotlin/nl/voidcorp/dbot/music/TrackScheduler.kt b/src/main/kotlin/nl/voidcorp/dbot/music/TrackScheduler.kt index 6388f73..4eb8770 100644 --- a/src/main/kotlin/nl/voidcorp/dbot/music/TrackScheduler.kt +++ b/src/main/kotlin/nl/voidcorp/dbot/music/TrackScheduler.kt @@ -30,8 +30,11 @@ class TrackScheduler(val player: AudioPlayer, val guild: Guild, channel: VoiceCh audio.sendingHandler = AudioPlayerSendHandler(player) audio.openAudioConnection(channel) - musicChannel = guild.getTextChannelsByName("music", true).firstOrNull() ?: (guild.getTextChannelsByName("general", true).firstOrNull() - ?: guild.defaultChannel!!) + musicChannel = guild.getTextChannelsByName("music-bot", true).firstOrNull() + ?: (guild.getTextChannelsByName("music", true).firstOrNull() + ?: (guild.getTextChannelsByName("bot", true).firstOrNull() + ?: (guild.getTextChannelsByName("general", true).firstOrNull() + ?: guild.defaultChannel!!))) }