diff --git a/frameworks/Java/smart-socket/src/main/java/org/smartboot/http/MultipleQueriesHandler.java b/frameworks/Java/smart-socket/src/main/java/org/smartboot/http/MultipleQueriesHandler.java index 3ead0475962..07147048a34 100644 --- a/frameworks/Java/smart-socket/src/main/java/org/smartboot/http/MultipleQueriesHandler.java +++ b/frameworks/Java/smart-socket/src/main/java/org/smartboot/http/MultipleQueriesHandler.java @@ -1,7 +1,7 @@ package org.smartboot.http; -import tech.smartboot.feat.core.common.utils.NumberUtils; +import tech.smartboot.feat.core.common.FeatUtils; import tech.smartboot.feat.core.server.HttpHandler; import tech.smartboot.feat.core.server.HttpRequest; import tech.smartboot.feat.core.server.HttpResponse; @@ -31,7 +31,7 @@ public void handle(HttpRequest httpRequest, CompletableFuture completableF HttpResponse response = httpRequest.getResponse(); Thread.startVirtualThread(() -> { try { - int queries = Math.min(Math.max(NumberUtils.toInt(httpRequest.getParameter("queries"), 1), 1), 500); + int queries = Math.min(Math.max(FeatUtils.toInt(httpRequest.getParameter("queries"), 1), 1), 500); World[] worlds = new World[queries]; try (Connection connection = dataSource.getConnection(); PreparedStatement preparedStatement = connection.prepareStatement("SELECT * FROM World WHERE id=?");) { diff --git a/frameworks/Java/smart-socket/src/main/java/org/smartboot/http/UpdateHandler.java b/frameworks/Java/smart-socket/src/main/java/org/smartboot/http/UpdateHandler.java index b2b37a5f424..85d990a71b4 100644 --- a/frameworks/Java/smart-socket/src/main/java/org/smartboot/http/UpdateHandler.java +++ b/frameworks/Java/smart-socket/src/main/java/org/smartboot/http/UpdateHandler.java @@ -1,7 +1,7 @@ package org.smartboot.http; -import tech.smartboot.feat.core.common.utils.NumberUtils; +import tech.smartboot.feat.core.common.FeatUtils; import tech.smartboot.feat.core.server.HttpHandler; import tech.smartboot.feat.core.server.HttpRequest; import tech.smartboot.feat.core.server.HttpResponse; @@ -29,7 +29,7 @@ public UpdateHandler(DataSource dataSource) { @Override public void handle(HttpRequest request) throws IOException { HttpResponse response = request.getResponse(); - int queries = Math.min(Math.max(NumberUtils.toInt(request.getParameter("queries"), 1), 1), 500); + int queries = Math.min(Math.max(FeatUtils.toInt(request.getParameter("queries"), 1), 1), 500); World[] worlds = new World[queries]; StringJoiner updateSql = new StringJoiner( ", ",