Pull request #111: RED-1019: Fixed returning numberOfPages

Merge in RED/redaction-service from RED-1019 to master

* commit '1ed99412595b560d92e542d949e52d19d58beb2c':
  RED-1019: Fixed returning numberOfPages
This commit is contained in:
Dominique Eiflaender 2021-01-29 13:32:05 +01:00
commit 6b68890fcf

View File

@ -64,8 +64,12 @@ public class RedactionController implements RedactionResource {
log.info("Redaction analysis successful..."); log.info("Redaction analysis successful...");
return AnalyzeResult.builder().sectionGrid(classifiedDoc.getSectionGrid()).redactionLog(new RedactionLog(classifiedDoc.getRedactionLogEntities(), classifiedDoc.getDictionaryVersion(), classifiedDoc return AnalyzeResult.builder()
.getRulesVersion(), analyzeRequest.getRuleSetId())).build(); .sectionGrid(classifiedDoc.getSectionGrid())
.redactionLog(new RedactionLog(classifiedDoc.getRedactionLogEntities(), classifiedDoc.getDictionaryVersion(), classifiedDoc
.getRulesVersion(), analyzeRequest.getRuleSetId()))
.numberOfPages(classifiedDoc.getPages().size())
.build();
} catch (Exception e) { } catch (Exception e) {
throw new RedactionException(e); throw new RedactionException(e);