mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-31 17:39:05 +00:00
RM-3651: workaround to skip code execution when first element is not a
record
This commit is contained in:
@@ -243,6 +243,8 @@ public class RecordsManagementNotificationHelper implements RecordsManagementMod
|
|||||||
{
|
{
|
||||||
ParameterCheck.mandatory("records", records);
|
ParameterCheck.mandatory("records", records);
|
||||||
if (!records.isEmpty())
|
if (!records.isEmpty())
|
||||||
|
{
|
||||||
|
if (nodeService.hasAspect(records.get(0), RecordsManagementModel.ASPECT_RECORD))
|
||||||
{
|
{
|
||||||
NodeRef root = getRMRoot(records.get(0));
|
NodeRef root = getRMRoot(records.get(0));
|
||||||
String groupName = getGroupName(root);
|
String groupName = getGroupName(root);
|
||||||
@@ -271,7 +273,9 @@ public class RecordsManagementNotificationHelper implements RecordsManagementMod
|
|||||||
logger.warn("Unable to send record due for review email notification, because notification group was empty.");
|
logger.warn("Unable to send record due for review email notification, because notification group was empty.");
|
||||||
}
|
}
|
||||||
|
|
||||||
throw new AlfrescoRuntimeException("Unable to send record due for review email notification, because notification group was empty.");
|
throw new AlfrescoRuntimeException(
|
||||||
|
"Unable to send record due for review email notification, because notification group was empty.");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user