forked from Upstream/CommandPanels
Combine two if-statements to hopefully pass code checks
This commit is contained in:
parent
e4c2adc822
commit
8a176ed18b
@ -345,9 +345,8 @@ public class ItemCreation {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 1.20 Trim Feature for Player Armor
|
// 1.20 Trim Feature for Player Armor
|
||||||
if(plugin.legacy.LOCAL_VERSION.greaterThanOrEqualTo(MinecraftVersions.v1_20)){
|
if(plugin.legacy.LOCAL_VERSION.greaterThanOrEqualTo(MinecraftVersions.v1_20) && itemSection.contains("trim")){
|
||||||
// trim: <Material> <Pattern>
|
// trim: <Material> <Pattern>
|
||||||
if(itemSection.contains("trim")){
|
|
||||||
String trim = itemSection.getString("trim");
|
String trim = itemSection.getString("trim");
|
||||||
String[] trimList = trim.split("\\s");
|
String[] trimList = trim.split("\\s");
|
||||||
if(trimList.length == 2){
|
if(trimList.length == 2){
|
||||||
@ -368,7 +367,6 @@ public class ItemCreation {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (itemSection.contains("stack")) {
|
if (itemSection.contains("stack")) {
|
||||||
//change the stack amount (placeholders accepted)
|
//change the stack amount (placeholders accepted)
|
||||||
s.setAmount((int)Double.parseDouble(Objects.requireNonNull(plugin.tex.placeholders(panel,position,p,itemSection.getString("stack")))));
|
s.setAmount((int)Double.parseDouble(Objects.requireNonNull(plugin.tex.placeholders(panel,position,p,itemSection.getString("stack")))));
|
||||||
|
Loading…
Reference in New Issue
Block a user