Skip to content
This repository was archived by the owner on Mar 4, 2020. It is now read-only.

Commit 32a1d37

Browse files
codebyterezcbenz
authored andcommitted
FIXME: use redefined version of internalModuleStat
Instantiate redefined version of the internalModuleStat function (see lib/common/asar.js in the electron/electron repo). For some reason this has to be done after the upgrade to the Node.js v8.7.0. `const internalModuleStat` in the very beginning of the file holds a reference to a native Node.js implementation of the function.
1 parent 5bacb64 commit 32a1d37

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

lib/internal/modules/cjs/loader.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,8 @@ const isWindows = process.platform === 'win32';
9494
let requireDepth = 0;
9595
let statCache = new Map();
9696
function stat(filename) {
97+
// FIXME(codebytere): determine why this needs to be done and remove
98+
const internalModuleStat = process.binding('fs').internalModuleStat;
9799
filename = path.toNamespacedPath(filename);
98100
if (statCache === null) statCache = new Map();
99101
let result = statCache.get(filename);

0 commit comments

Comments
 (0)