mirror of
https://github.com/ChestShop-authors/ChestShop-3.git
synced 2024-11-27 04:25:14 +01:00
Properly split the material name (Fixes #114)
This commit is contained in:
parent
d04e17450b
commit
26ddb52434
@ -281,8 +281,8 @@ public class MaterialUtil {
|
||||
return null;
|
||||
}
|
||||
|
||||
for (int index = split[0].indexOf(' '); index >= 0; index = split[0].indexOf(' ', index + 1)) {
|
||||
material = getMaterial(split[0].substring(index));
|
||||
for (int index = split[0].indexOf(' '); index >= 0 && index + 1 < split[0].length(); index = split[0].indexOf(' ', index + 1)) {
|
||||
material = getMaterial(split[0].substring(index + 1));
|
||||
|
||||
if (material != null) {
|
||||
if (durability == 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user