mirror of
https://github.com/stleary/JSON-java.git
synced 2026-01-25 00:00:38 -05:00
add a comment explaining the ordering
This commit is contained in:
@@ -2701,6 +2701,7 @@ public class JSONObject {
|
|||||||
if (value == null || value.equals(null)) {
|
if (value == null || value.equals(null)) {
|
||||||
writer.write("null");
|
writer.write("null");
|
||||||
} else if (value instanceof JSONString) {
|
} else if (value instanceof JSONString) {
|
||||||
|
// JSONString must be checked first, so it can overwrite behaviour of other types below
|
||||||
Object o;
|
Object o;
|
||||||
try {
|
try {
|
||||||
o = ((JSONString) value).toJSONString();
|
o = ((JSONString) value).toJSONString();
|
||||||
|
|||||||
Reference in New Issue
Block a user