if (participant.isInternal()) {
toNotify.add(((InternalPhdParticipant) participant).getPerson());
} else {
Unit unit = process.getAdministrativeOffice().getUnit();
UnitBasedSender sender = unit.getUnitBasedSenderSet().iterator().next();
new Message(sender, Collections.<ReplyTo> emptyList(), Collections.<Recipient> emptyList(), getSubjectPrefixed(
process, subject), getBodyText(process, body), Collections.singleton(participant.getEmail()));
}
}
if (!toNotify.isEmpty()) {