RSS-292: Fixed sorting problem is scm

This commit is contained in:
deiflaender 2022-12-09 13:32:59 +01:00
parent f5d7ca2a91
commit f798bab6b0
2 changed files with 3 additions and 2 deletions

View File

@ -2,6 +2,7 @@ package com.iqser.red.service.redaction.report.v1.server.controller;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
@ -33,7 +34,7 @@ public class RSSController implements RSSResource {
List<RSSFileResponse> fileResponses = new ArrayList<>();
for (DetailedRSSFileResponse detailedRSSFileResponse : detailed.getFiles()){
String fileName = detailedRSSFileResponse.getFilename();
Map<String, String> result = new HashMap<>();
Map<String, String> result = new LinkedHashMap<>();
for(Map.Entry<String, SCMComponent> detailedRss : detailedRSSFileResponse.getResult().entrySet()){
if(detailedRss.getValue().getValue() != null){
result.put(detailedRss.getKey(), detailedRss.getValue().getValue());

View File

@ -580,7 +580,7 @@ public class RSSPoc2Service {
var uniqueEntries = redactionLog.getRedactionLogEntry().stream().filter(r -> r.getType().equals(type)).collect(Collectors.toSet());
String value = uniqueEntries.stream().map(RedactionLogEntry::getValue).collect(Collectors.joining(seperator)).trim();
String value = uniqueEntries.stream().map(RedactionLogEntry::getValue).collect(Collectors.toSet()).stream().collect(Collectors.joining(seperator)).trim();
return SCMComponent.builder()
.originalValue(value)