diff --git a/redaction-service-v1/redaction-service-server-v1/src/main/java/com/iqser/red/service/redaction/v1/server/visualization/service/AnnotationHighlightService.java b/redaction-service-v1/redaction-service-server-v1/src/main/java/com/iqser/red/service/redaction/v1/server/visualization/service/AnnotationHighlightService.java index 072bc8bb..60757e68 100644 --- a/redaction-service-v1/redaction-service-server-v1/src/main/java/com/iqser/red/service/redaction/v1/server/visualization/service/AnnotationHighlightService.java +++ b/redaction-service-v1/redaction-service-server-v1/src/main/java/com/iqser/red/service/redaction/v1/server/visualization/service/AnnotationHighlightService.java @@ -105,11 +105,13 @@ public class AnnotationHighlightService { continue; } - RedactionLogEntry redactionLogEntry = createRedactionLogEntry(entity); + boolean requestedToRemove = false; List comments = null; for (EntityPositionSequence entityPositionSequence : entity.getPositionSequences()) { + + RedactionLogEntry redactionLogEntry = createRedactionLogEntry(entity); if (processedIds.contains(entityPositionSequence.getId())) { // TODO refactor this outer loop jump as soon as we have the time. @@ -159,12 +161,14 @@ public class AnnotationHighlightService { } redactionLogEntry.setId(entityPositionSequence.getId()); + + // FIXME ids should never be null. Figure out why this happens. + if (redactionLogEntry.getId() != null) { + classifiedDoc.getRedactionLogEntities().add(redactionLogEntry); + } } - // FIXME ids should never be null. Figure out why this happens. - if (redactionLogEntry.getId() != null) { - classifiedDoc.getRedactionLogEntities().add(redactionLogEntry); - } + } }