Use the connection we open

This commit is contained in:
Dan Mulloy 2018-02-25 22:02:07 -05:00 committed by Alexander Meech
parent 3ed1cc7868
commit 3cf61f71ed

View File

@ -64,12 +64,12 @@ public class CommunityRepository extends RepositoryBase
_repo = statusRepo;
_us = us;
}
public void communityExists(String name, Runnable onTrue, Runnable onFalse)
{
try (Connection connection = getConnection())
{
executeQuery("SELECT name FROM communities WHERE name=?", resultSet ->
executeQuery(connection, "SELECT name FROM communities WHERE name=?", resultSet ->
{
if (resultSet.next())
{