fix(#887): corrected small typo

This commit is contained in:
rikkarth 2024-04-14 23:23:06 +01:00
parent fe597d296e
commit ce074e9f9a
No known key found for this signature in database
GPG Key ID: 11E5F28B0AED6AC7

View File

@ -107,7 +107,7 @@ public class JSONArray implements Iterable<Object> {
}
if (nextChar != ']') {
x.back();
for (;;) {
for (; ; ) {
if (x.nextClean() == ',') {
x.back();
this.myArrayList.add(JSONObject.NULL);
@ -158,9 +158,9 @@ public class JSONArray implements Iterable<Object> {
* @throws JSONException if input is not compliant with strict mode guidelines;
*/
private void validateInput(JSONTokener x) {
char nextChar = x.getPrevious();
char cursor = x.getPrevious();
boolean isEndOfArray = nextChar == ']';
boolean isEndOfArray = cursor == ']';
boolean nextCharacterIsNotEoF = x.nextClean() != 0;
if (isEndOfArray && nextCharacterIsNotEoF) {