RED-3616: Fixed removing not redaction images that intersects imported redactions

This commit is contained in:
deiflaender 2022-04-12 09:46:50 +02:00
parent c963c7ac32
commit fbd9bc71a8

View File

@ -69,7 +69,7 @@ public class RedactionLogMergeService {
redactionLog.getRedactionLogEntry().removeIf(entry -> {
if(entry.getImportedRedactionIntersections() != null) {
entry.getImportedRedactionIntersections().removeAll(skippedImportedRedactions);
if (!entry.getImportedRedactionIntersections().isEmpty() && (!entry.isImage() || entry.isImage() && !entry.isRedacted())) {
if (!entry.getImportedRedactionIntersections().isEmpty() && (!entry.isImage() || entry.isImage() && !(entry.getType().equals("image") || entry.getType().equals("ocr")))) {
return true;
}
}