mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-26 03:29:00 +01:00
Reduce usage of require (#166051)
* Reduce usage of `require` * Bootstrap's callback returns only the first required module
This commit is contained in:
4
src/bootstrap-window.js
vendored
4
src/bootstrap-window.js
vendored
@@ -175,11 +175,11 @@
|
||||
}
|
||||
|
||||
// Actually require the main module as specified
|
||||
require(modulePaths, async result => {
|
||||
require(modulePaths, async firstModule => {
|
||||
try {
|
||||
|
||||
// Callback only after process environment is resolved
|
||||
const callbackResult = resultCallback(result, configuration);
|
||||
const callbackResult = resultCallback(firstModule, configuration);
|
||||
if (callbackResult instanceof Promise) {
|
||||
await callbackResult;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user