mirror of
https://github.com/Auxilor/EcoEnchants.git
synced 2024-12-28 20:47:37 +01:00
Fixed storing null targets
This commit is contained in:
parent
cbf40663e1
commit
e5aacc2ef8
@ -93,8 +93,10 @@ public class EnchantmentConfig extends EnchantmentYamlConfig {
|
|||||||
Set<EnchantmentTarget> targets = new HashSet<>();
|
Set<EnchantmentTarget> targets = new HashSet<>();
|
||||||
|
|
||||||
targetNames.forEach((s -> {
|
targetNames.forEach((s -> {
|
||||||
if(EnchantmentTarget.getByName(s) == null)
|
if(EnchantmentTarget.getByName(s) == null) {
|
||||||
Logger.error(s + " is an invalid target!");
|
Logger.error(s + " is an invalid target!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
targets.add(EnchantmentTarget.getByName(s));
|
targets.add(EnchantmentTarget.getByName(s));
|
||||||
}));
|
}));
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user