test for optional attribute

git-svn-id: http://scm.dspace.org/svn/repo/dspace/trunk@5701 9c30dcfa-912a-0410-8fc2-9e0234be79fd
This commit is contained in:
Richard Rodgers
2010-10-31 23:34:11 +00:00
parent 69b9c35b0f
commit 2beac7527e

View File

@@ -285,8 +285,10 @@ public class WorkflowCurator {
} else if ("taskset".equals(eName)) {
taskSet = new TaskSet(reader.getAttributeValue(0));
} else if ("flowstep".equals(eName)) {
flowStep = new FlowStep(reader.getAttributeValue(0),
reader.getAttributeValue(1));
int count = reader.getAttributeCount();
String queue = (count == 2) ?
reader.getAttributeValue(1) : null;
flowStep = new FlowStep(reader.getAttributeValue(0), queue);
} else if ("task".equals(eName)) {
task = new Task(reader.getAttributeValue(0));
} else if ("workflow".equals(eName)) {