Chromium Code Reviews| Index: Source/bindings/core/v8/NPV8Object.cpp |
| diff --git a/Source/bindings/core/v8/NPV8Object.cpp b/Source/bindings/core/v8/NPV8Object.cpp |
| index 6db91ed61db76b81029da21c1b54e55dcfe49624..c547ed24d4e3c6b5964915b88d4827ac3768af2b 100644 |
| --- a/Source/bindings/core/v8/NPV8Object.cpp |
| +++ b/Source/bindings/core/v8/NPV8Object.cpp |
| @@ -555,8 +555,9 @@ bool _NPN_Enumerate(NPP npp, NPObject* npObject, NPIdentifier** identifier, uint |
| " return props;" |
| "});"; |
| v8::Handle<v8::String> source = v8AtomicString(isolate, enumeratorCode); |
| - v8::Handle<v8::Value> result = V8ScriptRunner::compileAndRunInternalScript(source, isolate); |
| - ASSERT(!result.IsEmpty()); |
| + v8::Local<v8::Value> result; |
| + if (!V8ScriptRunner::compileAndRunInternalScript(source, isolate).ToLocal(&result)) |
|
dcarney
2015/03/13 08:15:45
use macros to remove the if(!whatever) block in mo
bashi
2015/03/17 02:01:36
We discussed how we handle ToLocal failure, and we
|
| + return false; |
| ASSERT(result->IsFunction()); |
| v8::Handle<v8::Function> enumerator = v8::Handle<v8::Function>::Cast(result); |
| v8::Handle<v8::Value> argv[] = { obj }; |