Skip to content
Snippets Groups Projects
Commit 51dd5e71 authored by srosse's avatar srosse
Browse files

OO-2032: check if the command exists

parent 9b18a8f6
No related branches found
No related tags found
No related merge requests found
......@@ -113,7 +113,9 @@ public class ChoiceItemController extends BasicController implements ControllerE
String sPosid = ureq.getParameter("posid");
int posid = 0;
if (sPosid != null) posid = Integer.parseInt(sPosid);
if (cmd.equals("up")) {
if(cmd == null) {
//ignore null cmd
} else if (cmd.equals("up")) {
if (posid > 0) {
List<Response> elements = item.getQuestion().getResponses();
Response obj = elements.remove(posid);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment