Skip to content

Commit

Permalink
fixed Utils.FileSystem overwriting 'fs' module even when 'original-fs…
Browse files Browse the repository at this point in the history
…' is broken
  • Loading branch information
devsnd committed Oct 18, 2018
1 parent 044a235 commit da9a6a1
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion util/fileSystem.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@ exports.require = function() {
var fs = require("fs");
if (process.versions['electron']) {
try {
fs = require("original-fs")
originalFs = require("original-fs");
if (Object.keys(originalFs).length > 0) {
fs = originalFs;
}
} catch (e) {}
}
return fs
Expand Down

0 comments on commit da9a6a1

Please sign in to comment.