Pull request #283: Hotfix for duplicate entries in redactionLog
Merge in RED/redaction-service from DuplicateIdsMaster to master * commit '46d14cfc6441588ee57e19d4780ffebcf70e3367': Hotfix for duplicate entries in redactionLog
This commit is contained in:
commit
809c563934
@ -54,6 +54,15 @@ public class RedactionLogMergeService {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Set<String> processedIds = new HashSet<>();
|
||||||
|
redactionLog.getRedactionLogEntry().removeIf(entry -> {
|
||||||
|
if(processedIds.contains(entry.getId())){
|
||||||
|
log.info("Duplicate annotation found with id {}", entry.getId());
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
processedIds.add(entry.getId());
|
||||||
|
return false;
|
||||||
|
});
|
||||||
return redactionLog;
|
return redactionLog;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user