0
0
mirror of https://github.com/phpv8/v8js.git synced 2024-11-10 04:58:41 +00:00

Don't explicitly indicate constructor, let V8 figure out

The GetConstructor function was removed from v8::Object which
would require some work to find out.  But V8 can do it
internally, so just leave it to V8 :)
This commit is contained in:
Stefan Siegl 2014-08-10 13:58:02 +02:00
parent 50fdfc5c88
commit 50b36d2cf5

View File

@ -654,7 +654,9 @@ static inline v8::Local<v8::Value> php_v8js_named_property_callback(v8::Local<v8
) {
if (callback_type == V8JS_PROP_GETTER) {
if (is_constructor) {
ret_value = self->GetConstructor();
// Don't set a return value here, i.e. indicate that we don't
// have a special value. V8 "knows" the constructor anyways
// (from the template) and will use that.
} else {
if (is_magic_call && method_ptr==NULL) {
// Fake __call implementation