We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents eb97037 + 1a2c50b commit 3e8d1d1Copy full SHA for 3e8d1d1
src/main/java/org/json/CDL.java
@@ -183,7 +183,7 @@ public static String rowToString(JSONArray ja, char delimiter) {
183
Object object = ja.opt(i);
184
if (object != null) {
185
String string = object.toString();
186
- if (string.length() > 0 && (string.indexOf(delimiter) >= 0 ||
+ if (!string.isEmpty() && (string.indexOf(delimiter) >= 0 ||
187
string.indexOf('\n') >= 0 || string.indexOf('\r') >= 0 ||
188
string.indexOf(0) >= 0 || string.charAt(0) == '"')) {
189
sb.append('"');
0 commit comments