v1.1.2 #393

Merged
greg6775 merged 7 commits from greg-dev into master 2020-03-09 18:40:03 +01:00
Showing only changes of commit 6489ad6cc5 - Show all commits

View file

@ -53,7 +53,7 @@ public class Rethink {
private JSONArray getAsArray(String table, String where, String value) {
try {
String string = r.table(table).filter(row -> row.g(where.toLowerCase()).eq(value)).coerceTo("array").toJson().run(conn);
String string = r.table(table).filter(row -> row.g(where.toLowerCase()).eq(value)).coerceTo("array").toJson().run(conn).toString();
return new JSONArray(string);
} catch (NoSuchElementException e) {
return null;
@ -77,7 +77,7 @@ public class Rethink {
}
public JSONObject getObjectByID(String table, String id) {
String response = r.table(table).get(id).toJson().run(conn);
String response = r.table(table).get(id).toJson().run(conn).toString();
return new JSONObject(response);
}