REPO-2519, MNT-17113 Remove Error log if content node for thumbnail was deleted.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.2.N/root@137695 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Martin Muller
2017-06-19 09:50:51 +00:00
parent 0b7cc423ee
commit b9828bc2de
2 changed files with 119 additions and 1 deletions

View File

@@ -920,8 +920,20 @@ public class ThumbnailServiceImpl implements ThumbnailService,
NodeRef thumbnailNodeRef = childAssoc.getChildRef();
NodeRef sourceNodeRef = childAssoc.getParentRef();
// check if thumbnail node exists
if (thumbnailNodeRef == null || !nodeService.exists(thumbnailNodeRef))
{
logger.debug("Thumbnail node " + thumbnailNodeRef + " does not exist. It will be skipped");
continue;
}
// check if source node exists
if (sourceNodeRef == null || !nodeService.exists(sourceNodeRef))
{
logger.debug("Parent node " + sourceNodeRef + " does not exist. It will be skipped");
continue;
}
String thumbnailName = (String) nodeService.getProperty(thumbnailNodeRef, ContentModel.PROP_NAME);
//behaviourFilter.disableBehaviour(sourceNodeRef, ContentModel.ASPECT_VERSIONABLE);
// Update the parent node with the thumbnail update...
if (logger.isDebugEnabled())
{