diff --git a/src/node.cc b/src/node.cc index 240f1f2e3b00f3..5a10addcef8615 100644 --- a/src/node.cc +++ b/src/node.cc @@ -171,11 +171,11 @@ MaybeLocal ExecuteBootstrapper(Environment* env, MaybeLocal maybe_fn = NativeModuleEnv::LookupAndCompile(env->context(), id, parameters, env); - if (maybe_fn.IsEmpty()) { + Local fn; + if (!maybe_fn.ToLocal(&fn)) { return MaybeLocal(); } - Local fn = maybe_fn.ToLocalChecked(); MaybeLocal result = fn->Call(env->context(), Undefined(env->isolate()), arguments->size(),