mirror of
https://github.com/BentoBoxWorld/Limits.git
synced 2024-11-22 10:36:11 +01:00
Avoid using NumberUtils. Update dependencies.
This commit is contained in:
parent
68f696a46c
commit
eeafa239c4
4
pom.xml
4
pom.xml
@ -57,8 +57,8 @@
|
||||
<!-- Non-minecraft related dependencies -->
|
||||
<powermock.version>2.0.9</powermock.version>
|
||||
<!-- More visible way how to change dependency versions -->
|
||||
<spigot.version>1.16.5-R0.1-SNAPSHOT</spigot.version>
|
||||
<bentobox.version>1.18.0-SNAPSHOT</bentobox.version>
|
||||
<spigot.version>1.19.4-R0.1-SNAPSHOT</spigot.version>
|
||||
<bentobox.version>1.23.0-SNAPSHOT</bentobox.version>
|
||||
<!-- Revision variable removes warning about dynamic version -->
|
||||
<revision>${build.version}-SNAPSHOT</revision>
|
||||
<!-- Do not change unless you want different name for local builds. -->
|
||||
|
@ -5,7 +5,6 @@ import java.util.Locale;
|
||||
import java.util.Objects;
|
||||
import java.util.UUID;
|
||||
|
||||
import org.apache.commons.lang.math.NumberUtils;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.OfflinePlayer;
|
||||
@ -118,11 +117,12 @@ public class JoinListener implements Listener {
|
||||
return true;
|
||||
}
|
||||
// Check value
|
||||
if (!NumberUtils.isDigits(split[4])) {
|
||||
logError(name, perms.getPermission(), "the last part MUST be a number!");
|
||||
try {
|
||||
Integer.parseInt(split[4]);
|
||||
} catch(Exception e) {
|
||||
logError(name, perms.getPermission(), "the last part MUST be an integer!");
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user