Fixed dictionaryWithJSObject on arrays with null values

This commit is contained in:
Vladimir Pouzanov committed 2011-06-08 14:10:10 +03:00
1 parent aac09d8208
commit 5d26066e02
1 file changed
+11 -4
+11 -4
View File
@@ -176,11 +176,18 @@
for (; i < count; i++)
{
var thisValue = value[i];
if (thisValue.constructor === Object)
newValue.push([CPDictionary dictionaryWithJSObject:thisValue recursively:YES]);
if (thisValue === null)
{
newValue.push([CPNull null]);
}
else
newValue.push(thisValue);
{
if (thisValue.constructor === Object)
newValue.push([CPDictionary dictionaryWithJSObject:thisValue recursively:YES]);
else
newValue.push(thisValue);
}
}
value = newValue;