Merge branch 'RED-10644-master' into 'master'
RED-10644: Fixed dublicated entries with whitespace at the end Closes RED-10644 See merge request redactmanager/redaction-service!573
This commit is contained in:
commit
22b2a6474b
@ -985,11 +985,11 @@ public class EntityCreationService {
|
||||
return Optional.empty(); // Entity has been recategorized and should not be created at all.
|
||||
}
|
||||
TextEntity existingEntity = optionalTextEntity.get();
|
||||
if (existingEntity.getTextRange().equals(textRange)) {
|
||||
if (existingEntity.getTextRange().equals(trimmedTextRange)) {
|
||||
return optionalTextEntity; // exactly the same entity, return directly
|
||||
}
|
||||
if (!existingEntity.resized()) {
|
||||
addDuplicateEntityToGraph(existingEntity, textRange, node);
|
||||
addDuplicateEntityToGraph(existingEntity, trimmedTextRange, node);
|
||||
return optionalTextEntity; // If Entity has not been resized, insert as duplicate at appropriate position
|
||||
}
|
||||
return Optional.empty(); // Entity has been resized, if there are duplicates they should be treated there
|
||||
|
||||
@ -243,7 +243,7 @@ public abstract class AbstractRedactionIntegrationTest {
|
||||
public static void init() {
|
||||
|
||||
synchronized (PDFNet.class) {
|
||||
PDFNet.initialize("demo:1650351709282:7bd235e003000000004ec28a6743e1163a085e2115de2536ab6e2cfe5a");
|
||||
PDFNet.initialize("demo:admin@knecon.com:7ed45ca80200000000c1e1765b94afccf5bbc0cb8582fd932c602e286a");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -169,7 +169,7 @@ import lombok.extern.slf4j.Slf4j;
|
||||
public static void init() {
|
||||
|
||||
synchronized (PDFNet.class) {
|
||||
PDFNet.initialize("demo:1650351709282:7bd235e003000000004ec28a6743e1163a085e2115de2536ab6e2cfe5a");
|
||||
PDFNet.initialize("demo:admin@knecon.com:7ed45ca80200000000c1e1765b94afccf5bbc0cb8582fd932c602e286a");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user