summaryrefslogtreecommitdiffstats
path: root/src/script/api/qscriptvalue.cpp
diff options
context:
space:
mode:
authorKent Hansen <khansen@trolltech.com>2009-07-06 14:35:32 (GMT)
committerKent Hansen <khansen@trolltech.com>2009-07-06 14:35:32 (GMT)
commit9769235a26c3bacc597b994fa249516721833389 (patch)
tree60027b190da162077d9a3b1199ea3c6c56bca6a8 /src/script/api/qscriptvalue.cpp
parent2e571b141ce50349790ca943455427185442ed16 (diff)
downloadQt-9769235a26c3bacc597b994fa249516721833389.zip
Qt-9769235a26c3bacc597b994fa249516721833389.tar.gz
Qt-9769235a26c3bacc597b994fa249516721833389.tar.bz2
make QScriptClass::HasInstance extension work
Diffstat (limited to 'src/script/api/qscriptvalue.cpp')
-rw-r--r--src/script/api/qscriptvalue.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/script/api/qscriptvalue.cpp b/src/script/api/qscriptvalue.cpp
index ff2823b..bb8b2b7 100644
--- a/src/script/api/qscriptvalue.cpp
+++ b/src/script/api/qscriptvalue.cpp
@@ -865,7 +865,7 @@ bool QScriptValue::instanceOf(const QScriptValue &other) const
QScriptEnginePrivate *eng_p = QScriptEnginePrivate::get(d->engine);
JSC::JSValue jscProto = eng_p->scriptValueToJSCValue(other.property(QLatin1String("prototype")));
if (!jscProto)
- return false;
+ jscProto = JSC::jsUndefined();
JSC::ExecState *exec = eng_p->globalObject->globalExec();
JSC::JSValue jscOther = eng_p->scriptValueToJSCValue(other);
return JSC::asObject(jscOther)->hasInstance(exec, d->jscValue, jscProto);