@@ -373,7 +373,6 @@ MaybeLocal<Function> BuiltinLoader::LookupAndCompileInternal(
373
373
// Otherwise return a Local<Object> containing the cache.
374
374
MaybeLocal<Function> BuiltinLoader::LookupAndCompile (
375
375
Local<Context> context, const char * id, Environment* optional_env) {
376
- Result result;
377
376
std::vector<Local<String>> parameters;
378
377
Isolate* isolate = context->GetIsolate ();
379
378
// Detects parameters of the scripts based on module ids.
@@ -424,8 +423,17 @@ MaybeLocal<Function> BuiltinLoader::LookupAndCompile(
424
423
};
425
424
}
426
425
427
- MaybeLocal<Function> maybe = GetInstance ()->LookupAndCompileInternal (
428
- context, id, ¶meters, &result);
426
+ return LookupAndCompile (context, id, ¶meters, optional_env);
427
+ }
428
+
429
+ MaybeLocal<Function> BuiltinLoader::LookupAndCompile (
430
+ Local<Context> context,
431
+ const char * id,
432
+ std::vector<Local<String>>* parameters,
433
+ Environment* optional_env) {
434
+ Result result;
435
+ MaybeLocal<Function> maybe =
436
+ GetInstance ()->LookupAndCompileInternal (context, id, parameters, &result);
429
437
if (optional_env != nullptr ) {
430
438
RecordResult (id, result, optional_env);
431
439
}
0 commit comments