This is my code that causes the error:
public void onJoin(PlayerJoinEvent event ){
Player player = event.getPlayer();
if (this.rootdata.getBoolean("CustomJoin.custom-message")) {
final List<String> message = (List<String>)this.langdata.getStringList("CustomJoinMessage.message");
for (final String send : message) {
MsgUtil.sendMessage(player, send);
}
}
}