mirror of
https://github.com/phpv8/v8js.git
synced 2024-12-23 04:51:53 +00:00
Make compatible with V8 3.28.23, fixes #99
This commit is contained in:
parent
1d8ae1f458
commit
e25e5264f6
2
v8js.cc
2
v8js.cc
@ -914,7 +914,7 @@ static PHP_METHOD(V8Js, __construct)
|
|||||||
|
|
||||||
/* Add the PHP object into global object */
|
/* Add the PHP object into global object */
|
||||||
v8::Local<v8::Object> php_obj = php_obj_t->InstanceTemplate()->NewInstance();
|
v8::Local<v8::Object> php_obj = php_obj_t->InstanceTemplate()->NewInstance();
|
||||||
V8JS_GLOBAL(isolate)->Set(object_name_js, php_obj, v8::ReadOnly);
|
V8JS_GLOBAL(isolate)->ForceSet(object_name_js, php_obj, v8::ReadOnly);
|
||||||
|
|
||||||
/* Export public property values */
|
/* Export public property values */
|
||||||
HashTable *properties = zend_std_get_properties(getThis() TSRMLS_CC);
|
HashTable *properties = zend_std_get_properties(getThis() TSRMLS_CC);
|
||||||
|
@ -986,7 +986,7 @@ static v8::Handle<v8::Value> php_v8js_hash_to_jsobj(zval *value, v8::Isolate *is
|
|||||||
}
|
}
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
newobj->Set(V8JS_STRL(key, key_len - 1), zval_to_v8js(*data, isolate TSRMLS_CC), v8::ReadOnly);
|
newobj->Set(V8JS_STRL(key, key_len - 1), zval_to_v8js(*data, isolate TSRMLS_CC));
|
||||||
} else {
|
} else {
|
||||||
newobj->Set(index, zval_to_v8js(*data, isolate TSRMLS_CC));
|
newobj->Set(index, zval_to_v8js(*data, isolate TSRMLS_CC));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user