mirror of
https://github.com/songoda/EpicHoppers.git
synced 2024-11-29 13:45:24 +01:00
fixes SD305
This commit is contained in:
parent
189e4c5dcb
commit
f1637ca349
@ -465,7 +465,7 @@ public class EpicHoppersPlugin extends JavaPlugin implements EpicHoppers {
|
|||||||
@Override
|
@Override
|
||||||
public Level getLevelFromItem(ItemStack item) {
|
public Level getLevelFromItem(ItemStack item) {
|
||||||
if (item.getItemMeta().getDisplayName().contains(":")) {
|
if (item.getItemMeta().getDisplayName().contains(":")) {
|
||||||
String arr[] = item.getItemMeta().getDisplayName().replace("§", "").split(":");
|
String arr[] = item.getItemMeta().getDisplayName().replace(String.valueOf(ChatColor.COLOR_CHAR), "").split(":");
|
||||||
return getLevelManager().getLevel(Integer.parseInt(arr[0]));
|
return getLevelManager().getLevel(Integer.parseInt(arr[0]));
|
||||||
} else {
|
} else {
|
||||||
return getLevelManager().getLowestLevel();
|
return getLevelManager().getLowestLevel();
|
||||||
|
Loading…
Reference in New Issue
Block a user