diff --git a/tools/cldr-code/src/main/java/org/unicode/cldr/json/Ldml2JsonConverter.java b/tools/cldr-code/src/main/java/org/unicode/cldr/json/Ldml2JsonConverter.java index 978a277afbf..32bf5429df7 100644 --- a/tools/cldr-code/src/main/java/org/unicode/cldr/json/Ldml2JsonConverter.java +++ b/tools/cldr-code/src/main/java/org/unicode/cldr/json/Ldml2JsonConverter.java @@ -2264,9 +2264,16 @@ private void writeLeafNode( // out.name(objName); if (value.isEmpty()) { if (valueIsSpacesepArray) { + // empty value, output as empty space-sep array: [] out.getAsJsonObject().add(objName, new JsonArray()); } else { - out.getAsJsonObject().add(objName, new JsonObject()); + // empty value. + if (objName.endsWith("SpaceReplacement")) { // foreignSpaceReplacement or + // nativeSpaceReplacement + out.getAsJsonObject().addProperty(objName, ""); + } else { + out.getAsJsonObject().add(objName, new JsonObject()); + } } } else if (type == RunType.annotations || type == RunType.annotationsDerived) { JsonArray a = new JsonArray();