This is an automated email from the ASF dual-hosted git repository.
ab pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/lucene-solr.git
The following commit(s) were added to refs/heads/master by this push:
new 969f9c1 SOLR-14691: Fix a minor back-compat formatting issue.
969f9c1 is described below
commit 969f9c189942f860217005882cba1378c898d22f
Author: Andrzej Bialecki <ab@apache.org>
AuthorDate: Wed Oct 7 20:46:13 2020 +0200
SOLR-14691: Fix a minor back-compat formatting issue.
---
solr/solrj/src/java/org/apache/solr/common/util/Utils.java | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/solr/solrj/src/java/org/apache/solr/common/util/Utils.java b/solr/solrj/src/java/org/apache/solr/common/util/Utils.java
index c05ce23..86bef91 100644
--- a/solr/solrj/src/java/org/apache/solr/common/util/Utils.java
+++ b/solr/solrj/src/java/org/apache/solr/common/util/Utils.java
@@ -234,13 +234,14 @@ public class Utils {
startObject();
final boolean[] first = new boolean[1];
first[0] = true;
+ int sz = mapWriter._size();
mapWriter._forEachEntry((k, v) -> {
if (first[0]) {
first[0] = false;
} else {
writeValueSeparator();
}
- indent();
+ if (sz > 1) indent();
writeString(k.toString());
writeNameSeparator();
write(v);
|