mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Merged BRANCHES/DEV/V3.3-BUG-FIX to HEAD:
22237: Fix ALF-3986: decrement original owner usage (if content deleted by a different user) git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@22339 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -367,10 +367,15 @@ public class ContentUsageImpl implements ContentUsageService,
|
||||
long contentSize = contentData.getSize();
|
||||
|
||||
// Get owner/creator
|
||||
String owner = (String)nodeService.getProperty(nodeRef, ContentModel.PROP_OWNER);
|
||||
if ((owner == null) || (owner.equals(OwnableService.NO_OWNER)))
|
||||
String owner = (String)nodeService.getProperty(nodeRef, ContentModel.PROP_ARCHIVED_ORIGINAL_OWNER); // allow for case where someone else is deleting the node
|
||||
if (owner == null)
|
||||
{
|
||||
owner = (String)nodeService.getProperty(nodeRef, ContentModel.PROP_CREATOR);
|
||||
|
||||
owner = (String)nodeService.getProperty(nodeRef, ContentModel.PROP_OWNER);
|
||||
if ((owner == null) || (owner.equals(OwnableService.NO_OWNER)))
|
||||
{
|
||||
owner = (String)nodeService.getProperty(nodeRef, ContentModel.PROP_CREATOR);
|
||||
}
|
||||
}
|
||||
|
||||
if (contentSize != 0 && owner != null)
|
||||
|
Reference in New Issue
Block a user