| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 5fb1cc8 commit a522c0e
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -284,14 +284,14 @@ MaybeLocal<Function> NativeModuleLoader::LookupAndCompile( | |||
| 284 | 284 | ||
| 285 | 285 | // This could fail when there are early errors in the native modules, | |
| 286 | 286 | // e.g. the syntax errors | |
| 287 | - if (maybe_fun.IsEmpty()) { | ||
| 287 | + Local<Function> fun; | ||
| 288 | + if (!maybe_fun.ToLocal(&fun)) { | ||
| 288 | 289 | // In the case of early errors, v8 is already capable of | |
| 289 | 290 | // decorating the stack for us - note that we use CompileFunctionInContext | |
| 290 | 291 | // so there is no need to worry about wrappers. | |
| 291 | 292 | return MaybeLocal<Function>(); | |
| 292 | 293 | } | |
| 293 | 294 | ||
| 294 | - Local<Function> fun = maybe_fun.ToLocalChecked(); | ||
| 295 | 295 | // XXX(joyeecheung): this bookkeeping is not exactly accurate because | |
| 296 | 296 | // it only starts after the Environment is created, so the per_context.js | |
| 297 | 297 | // will never be in any of these two sets, but the two sets are only for | |
| Back | FazBrowse Home | New Git URL |
0 commit comments