Commit 9df61650 authored by Tagir Valeev's avatar Tagir Valeev Committed by daryl herzmann

max_items reading is fixed (#612)

OF-1157
parent 967d632e
......@@ -69,7 +69,7 @@ public class GetListActiveUsers extends AdHocCommand {
public void execute(SessionData data, Element command) {
String max_items = data.getData().get("max_items").get(0);
int maxItems = -1;
if (max_items != null && "none".equals(max_items)) {
if (max_items != null && !"none".equals(max_items)) {
try {
maxItems = Integer.parseInt(max_items);
}
......
......@@ -73,7 +73,7 @@ public class GetUsersPresence extends AdHocCommand {
public void execute(SessionData data, Element command) {
String max_items = data.getData().get("max_items").get(0);
int maxItems = -1;
if (max_items != null && "none".equals(max_items)) {
if (max_items != null && !"none".equals(max_items)) {
try {
maxItems = Integer.parseInt(max_items);
}
......
......@@ -99,7 +99,7 @@ public class GetListGroups extends AdHocCommand {
}
}
int maxItems = 100000;
if (max_items != null && "none".equals(max_items)) {
if (max_items != null && !"none".equals(max_items)) {
try {
maxItems = Integer.parseInt(max_items);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment