FIXME: Use redefined version of the `internalModuleStat` function
(cherry picked from commit 68da904c6ccdefe94deb04bde510f60f331d35b5)
This commit is contained in:
Родитель
c8d1dd49a1
Коммит
73d1703470
|
@ -85,6 +85,13 @@ const {
|
|||
const localGlobal = global;
|
||||
|
||||
function stat(filename) {
|
||||
// FIXME(alexeykuzmin): Get a redefined version of the `internalModuleStat`
|
||||
// function (see "lib/common/asar.js" in the electron/electron repo).
|
||||
// For some reason it 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.
|
||||
const internalModuleStat = process.binding('fs').internalModuleStat;
|
||||
|
||||
filename = path.toNamespacedPath(filename);
|
||||
const cache = stat.cache;
|
||||
if (cache !== null) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче