From 591b2f5e7113015bd7b47a314f9f5bb2ac3d537f Mon Sep 17 00:00:00 2001 From: MrNavaStar Date: Sat, 20 Jul 2024 18:55:57 -0600 Subject: [PATCH] perhaps fix crash --- src/main/java/me/mrnavastar/sqlib/impl/SQLConnection.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/me/mrnavastar/sqlib/impl/SQLConnection.java b/src/main/java/me/mrnavastar/sqlib/impl/SQLConnection.java index 22b7fb9..5ae6785 100644 --- a/src/main/java/me/mrnavastar/sqlib/impl/SQLConnection.java +++ b/src/main/java/me/mrnavastar/sqlib/impl/SQLConnection.java @@ -64,7 +64,7 @@ public void deleteRow(DataStore store, int id) { public boolean rowExists(DataStore store, int id) { try (Handle h = sql.open()) { - return h.select("SELECT 1 FROM %s WHERE SQLIB_AUTO_ID = ?".formatted(store.toString()), id).mapTo(Object.class).one() != null; + return h.select("SELECT 1 FROM %s WHERE SQLIB_AUTO_ID = ?".formatted(store.toString()), id).mapTo(Integer.class).one() != null; } }