SEBSERV-252 fixed CSV export escaping

This commit is contained in:
anhefti 2021-12-06 10:57:42 +01:00
parent 3a65943bde
commit bd045b0d03

View file

@ -678,7 +678,11 @@ public final class Utils {
if (StringUtils.isBlank(text)) {
return StringUtils.EMPTY;
}
return Constants.DOUBLE_QUOTE + text.replace("\"", "\"\"") + Constants.DOUBLE_QUOTE;
return Constants.DOUBLE_QUOTE +
text
.replace("\r\n", "\n")
.replace("\"", "\"\"")
+ Constants.DOUBLE_QUOTE;
}
}