From 446bea86f5753bccd1772347aa1e753ddf2b44f8 Mon Sep 17 00:00:00 2001 From: Lars Knoll Date: Wed, 12 Dec 2012 09:00:19 +0100 Subject: [PATCH] Fix hasProperty internal method Change-Id: Ifd0b19d6ff011bb85475e6654681a022c8f58e2d Reviewed-by: Simon Hausmann --- qmljs_objects.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/qmljs_objects.cpp b/qmljs_objects.cpp index 431d508..d7d0365 100644 --- a/qmljs_objects.cpp +++ b/qmljs_objects.cpp @@ -255,8 +255,8 @@ void Object::__put__(ExecutionContext *ctx, String *name, Value value) // Section 8.12.6 bool Object::__hasProperty__(const ExecutionContext *ctx, String *name) const { - if (members) - return members->find(name) != 0; + if (members && members->find(name) != 0) + return true; return prototype ? prototype->__hasProperty__(ctx, name) : false; } -- 2.7.4