Index: third_party/WebKit/Source/bindings/tests/results/core/V8TestPermissiveDictionary.cpp |
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestPermissiveDictionary.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestPermissiveDictionary.cpp |
index 4d395e5b85baff576b0e94849ec57a2bb627f76b..e863895d63c26dca81d45e1bfb6ff329aac692cf 100644 |
--- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestPermissiveDictionary.cpp |
+++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestPermissiveDictionary.cpp |
@@ -52,9 +52,15 @@ v8::Local<v8::Value> TestPermissiveDictionary::toV8Impl(v8::Local<v8::Object> cr |
} |
bool toV8TestPermissiveDictionary(const TestPermissiveDictionary& impl, v8::Local<v8::Object> dictionary, v8::Local<v8::Object> creationContext, v8::Isolate* isolate) { |
+ v8::Local<v8::Value> booleanMemberValue; |
+ bool booleanMemberHasValueOrDefault = false; |
if (impl.hasBooleanMember()) { |
- if (!v8CallBoolean(dictionary->CreateDataProperty(isolate->GetCurrentContext(), v8AtomicString(isolate, "booleanMember"), v8Boolean(impl.booleanMember(), isolate)))) |
- return false; |
+ booleanMemberValue = v8Boolean(impl.booleanMember(), isolate); |
+ booleanMemberHasValueOrDefault = true; |
+ } |
+ if (booleanMemberHasValueOrDefault && |
+ !v8CallBoolean(dictionary->CreateDataProperty(isolate->GetCurrentContext(), v8AtomicString(isolate, "booleanMember"), booleanMemberValue))) { |
+ return false; |
} |
return true; |