diff --git a/src/main/java/com/github/creeper123123321/viarift/util/IntegerFormatFilter.java b/src/main/java/com/github/creeper123123321/viarift/util/IntegerFormatFilter.java index 29c3c88..12f7750 100644 --- a/src/main/java/com/github/creeper123123321/viarift/util/IntegerFormatFilter.java +++ b/src/main/java/com/github/creeper123123321/viarift/util/IntegerFormatFilter.java @@ -29,12 +29,16 @@ import java.util.function.Predicate; public class IntegerFormatFilter implements Predicate { @Override public boolean test(String s) { - if (s.isEmpty()) return true; try { Integer.parseInt(s); return true; } catch (NumberFormatException e) { - return false; + try { + Integer.parseInt(s + '0'); + return true; + } catch (NumberFormatException e2) { + return false; + } } } }