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

OO-4326: check if node really exists

parent 1957ae79
No related branches found
No related tags found
No related merge requests found
......@@ -108,7 +108,7 @@ public class PublishProcess {
private ICourse course;
private RepositoryEntry repositoryEntry;
//to be replaced
private PublishTreeModel publishTreeModel;
private final PublishTreeModel publishTreeModel;
/*
* intermediate structures to calculate next course run
......@@ -152,7 +152,9 @@ public class PublishProcess {
// avoid using iterator here so we can modify the Collection
String nodeId = nodeIdsToPublish.get(i);
CourseEditorTreeNode cetn = editorTreeModel.getCourseEditorNodeById(nodeId);
if (cetn.isNewnode() || cetn.isDeleted() || publishTreeModel.isMoved(cetn)) appendPublishableSubnodeIds(cetn, nodeIdsToPublish);
if (cetn != null && (cetn.isNewnode() || cetn.isDeleted() || publishTreeModel.isMoved(cetn))) {
appendPublishableSubnodeIds(cetn, nodeIdsToPublish);
}
}
/*
......
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