Fixed fishing drop tables error messages

This commit is contained in:
Indyuce 2020-08-27 12:52:24 +02:00
parent eef4013797
commit 1c9b0769b8
2 changed files with 3 additions and 1 deletions

View File

@ -1,5 +1,6 @@
package net.Indyuce.mmocore.api.droptable.dropitem.fishing;
import org.apache.commons.lang.Validate;
import org.bukkit.inventory.ItemStack;
import net.Indyuce.mmocore.MMOCore;
@ -23,6 +24,7 @@ public class FishingDropItem {
experience = new RandomAmount(config.getString("experience"));
weight = config.getInt("weight", 1);
Validate.isTrue(weight > 0, "A fishing drop table item cannot have 0 weight");
dropItem = MMOCore.plugin.loadManager.loadDropItem(config);
}

View File

@ -80,7 +80,7 @@ public class FishingManager extends MMOManager {
"Could not load item '" + str + "' from fishing drop table '" + id + "': " + exception.getMessage());
}
Validate.notEmpty(list, "The item list must not be empty.");
Validate.notEmpty(items, "The item list must not be empty.");
}
public boolean areConditionsMet(ConditionInstance entity) {