Fix broken recursive dump in DataReport.

This commit is contained in:
sk89q 2015-01-04 19:19:53 -08:00
parent 4333b39377
commit bab98d5463

View File

@ -103,7 +103,7 @@ private static String getStringValue(Object value, Set<Object> seen) {
} else {
builder.append("\n");
}
builder.append(getStringValue(entry, seen));
builder.append(getStringValue(entry, Sets.newHashSet(seen)));
}
return builder.toString();
} else if (value instanceof Map<?, ?>) {
@ -116,7 +116,7 @@ private static String getStringValue(Object value, Set<Object> seen) {
builder.append("\n");
}
String key = getStringValue(entry.getKey(), seen).replaceAll("[\r\n]", "");
String key = getStringValue(entry.getKey(), Sets.newHashSet(seen)).replaceAll("[\r\n]", "");
if (key.length() > 60) {
key = key.substring(0, 60) + "...";
}
@ -124,7 +124,7 @@ private static String getStringValue(Object value, Set<Object> seen) {
builder
.append(key)
.append(": ")
.append(getStringValue(entry.getValue(), seen));
.append(getStringValue(entry.getValue(), Sets.newHashSet(seen)));
}
return builder.toString();
} else {