diff --git a/eco-core/core-plugin/src/main/kotlin/com/willfp/ecopets/commands/CommandGiveXP.kt b/eco-core/core-plugin/src/main/kotlin/com/willfp/ecopets/commands/CommandGiveXP.kt index 89e740b..dc6a7d2 100644 --- a/eco-core/core-plugin/src/main/kotlin/com/willfp/ecopets/commands/CommandGiveXP.kt +++ b/eco-core/core-plugin/src/main/kotlin/com/willfp/ecopets/commands/CommandGiveXP.kt @@ -27,7 +27,10 @@ class CommandGiveXP(plugin: EcoPlugin) : Subcommand(plugin, "givexp", "ecopets.c if (args.size == 3){ player = Bukkit.getPlayer(args[2])!! } - if (!(player is Player)) return; + if (!(player is Player)) { + sender.sendMessage(plugin.langYml.getMessage("invalid-player")) + return + } val pet = Pets.getByID(args[0]) if (pet == null) {