mirror of
https://github.com/stleary/JSON-java.git
synced 2025-08-03 03:15:32 -04:00
update constructor call to match Android implementation
This commit is contained in:
parent
1736a60ffe
commit
3997a90d58
@ -40,7 +40,9 @@ public class Property {
|
||||
* @throws JSONException
|
||||
*/
|
||||
public static JSONObject toJSONObject(java.util.Properties properties) throws JSONException {
|
||||
JSONObject jo = new JSONObject(properties == null ? 0 : properties.size());
|
||||
// can't use the new constructor for Android support
|
||||
// JSONObject jo = new JSONObject(properties == null ? 0 : properties.size());
|
||||
JSONObject jo = new JSONObject();
|
||||
if (properties != null && !properties.isEmpty()) {
|
||||
Enumeration<?> enumProperties = properties.propertyNames();
|
||||
while(enumProperties.hasMoreElements()) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user