Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,10 @@ public void listenContentSaving(ProceedingJoinPoint pjp, Object content) {
String contentId = currentContent.getId();
if (null != contentId) {
Content previousContent = this.getContentManager().loadContent(contentId, false);
if (previousContent.getStatus().equals(currentContent.getStatus())) {
// previousContent is null when the content is being created with a caller-supplied id
// (e.g. a bundle install that preserves content ids): there is no prior work copy to
// compare against, so it IS a status change — keep notify = true rather than NPE.
if (previousContent != null && previousContent.getStatus().equals(currentContent.getStatus())) {
notify = false;
}
}
Expand Down
Loading