Skip to content

Commit 3ea0b34

Browse files
author
DvirDukhan
committed
changed try resource block (again)
1 parent 659f7c4 commit 3ea0b34

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/java/com/redislabs/redisgraph/RedisGraph.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,8 @@ public ResultSet query(String graphId, String query, Object ...args) {
8989
query = String.format(query, args);
9090
}
9191
graphCaches.putIfAbsent(graphId, new GraphCache(graphId, this));
92-
List<Object> rawResponse = new ArrayList<Object>();
93-
try(Jedis conn = getConnection();){
92+
List<Object> rawResponse = null;
93+
try(Jedis conn = getConnection()){
9494
rawResponse= sendCompactCommand(conn, Command.QUERY, graphId, query).getObjectMultiBulkReply();
9595
}
9696
return new ResultSetImpl(rawResponse, graphCaches.get(graphId));

0 commit comments

Comments
 (0)