This commit is contained in:
Jason Penilla committed 2024-06-25 11:05:46 -07:00
1 parent 49ed2f525e
commit a2f62f1e9c
1 file changed
+2 -1
@@ -408,7 +408,8 @@ public class CarbonChannelRegistry extends ChatListenerInternal implements Chann
// TODO: trigger platform events related to chat
this.sendMessageInChannel(player, chatChannel, message);
} else {
if (this.config.primaryConfig().returnToDefaultChannel() && player.selectedChannel().key().equals(channelKey)) {
final @Nullable ChatChannel fromChannel = player.selectedChannel();
if (this.config.primaryConfig().returnToDefaultChannel() && fromChannel != null && fromChannel.key().equals(channelKey)) {
chatChannel = this.defaultChannel();
}