Skip to content

Commit b426ddb

Browse files
authored
Merge branch 'stleary:master' into master
2 parents 1975c27 + 32e56da commit b426ddb

File tree

1 file changed

+0
-20
lines changed

1 file changed

+0
-20
lines changed

src/main/java/org/json/JSONObject.java

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -3012,24 +3012,4 @@ private static JSONException recursivelyDefinedObjectException(String key) {
30123012
"JavaBean object contains recursively defined member variable of key " + quote(key)
30133013
);
30143014
}
3015-
3016-
/**
3017-
* For a prospective number, remove the leading zeros
3018-
* @param value prospective number
3019-
* @return number without leading zeros
3020-
*/
3021-
private static String removeLeadingZerosOfNumber(String value){
3022-
if ("-".equals(value)){return value;}
3023-
boolean negativeFirstChar = (value.charAt(0) == '-');
3024-
int counter = negativeFirstChar ? 1:0;
3025-
while (counter < value.length()){
3026-
if (value.charAt(counter) != '0'){
3027-
if (negativeFirstChar) {return "-".concat(value.substring(counter));}
3028-
return value.substring(counter);
3029-
}
3030-
++counter;
3031-
}
3032-
if (negativeFirstChar) {return "-0";}
3033-
return "0";
3034-
}
30353015
}

0 commit comments

Comments
 (0)