File tree 1 file changed +4
-2
lines changed
minecord-chat/src/main/java/me/axieum/mcmod/minecord/impl/chat/util
1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change 5
5
import java .util .function .Predicate ;
6
6
7
7
import net .dv8tion .jda .api .EmbedBuilder ;
8
- import net .dv8tion .jda .api .entities .channel .concrete . TextChannel ;
8
+ import net .dv8tion .jda .api .entities .channel .middleman . GuildMessageChannel ;
9
9
import net .dv8tion .jda .api .requests .restaction .MessageCreateAction ;
10
10
import net .dv8tion .jda .api .utils .messages .MessageCreateBuilder ;
11
11
import org .jetbrains .annotations .Nullable ;
@@ -141,7 +141,9 @@ public static void dispatch(
141
141
// Build and queue each chat entry
142
142
.forEach (entry -> {
143
143
// Fetch the channel
144
- final @ Nullable TextChannel channel = jda .getTextChannelById (entry .id );
144
+ final @ Nullable GuildMessageChannel channel = jda .getChannelById (
145
+ GuildMessageChannel .class , entry .id
146
+ );
145
147
146
148
// Check that the channel exists
147
149
if (channel == null )
You can’t perform that action at this time.
0 commit comments