BATCH-1758: Fix PropertiesConverter corner case with round trips of short strings

This commit is contained in:
Dave Syer
2011-05-13 17:25:34 +01:00
parent dee8715f92
commit ca7eadd943
2 changed files with 24 additions and 5 deletions

View File

@@ -69,8 +69,8 @@ public final class PropertiesConverter {
}
if (!contains(stringToParse, "\n")) {
return StringUtils.splitArrayElementsIntoProperties(StringUtils
.commaDelimitedListToStringArray(stringToParse), "=");
stringToParse = StringUtils.arrayToDelimitedString(
StringUtils.commaDelimitedListToStringArray(stringToParse), "\n");
}
StringReader stringReader = new StringReader(stringToParse);