Skip to content

Commit 051c3ba

Browse files
committed
ENH: ujson python 3 defines
1 parent 5746bf1 commit 051c3ba

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

pandas/src/ujson/python/objToJSON.c

+4-4
Original file line numberDiff line numberDiff line change
@@ -1086,17 +1086,17 @@ void Object_beginTypeContext (JSOBJ _obj, JSONTypeContext *tc)
10861086
return;
10871087
}
10881088
else
1089-
if (PyString_Check(obj))
1089+
if (PyUnicode_Check(obj))
10901090
{
10911091
PRINTMARK();
1092-
pc->PyTypeToJSON = PyStringToUTF8; tc->type = JT_UTF8;
1092+
pc->PyTypeToJSON = PyUnicodeToUTF8; tc->type = JT_UTF8;
10931093
return;
10941094
}
10951095
else
1096-
if (PyUnicode_Check(obj))
1096+
if (PyString_Check(obj))
10971097
{
10981098
PRINTMARK();
1099-
pc->PyTypeToJSON = PyUnicodeToUTF8; tc->type = JT_UTF8;
1099+
pc->PyTypeToJSON = PyStringToUTF8; tc->type = JT_UTF8;
11001100
return;
11011101
}
11021102
else

0 commit comments

Comments
 (0)