Skip to content

Commit 1c408b0

Browse files
committed
Revert "fs: remove workaround for esm package"
This reverts commit 95b1989. It appears that the workaround is still needed: issue #51081
1 parent fc10f88 commit 1c408b0

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lib/internal/fs/utils.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -498,6 +498,10 @@ function Stats(dev, mode, nlink, uid, gid, rdev, blksize,
498498
ObjectSetPrototypeOf(Stats.prototype, StatsBase.prototype);
499499
ObjectSetPrototypeOf(Stats, StatsBase);
500500

501+
// HACK: Workaround for https://github.com/standard-things/esm/issues/821.
502+
// TODO(ronag): Remove this as soon as `esm` publishes a fixed version.
503+
Stats.prototype.isFile = StatsBase.prototype.isFile;
504+
501505
Stats.prototype._checkModeProperty = function(property) {
502506
if (isWindows && (property === S_IFIFO || property === S_IFBLK ||
503507
property === S_IFSOCK)) {

0 commit comments

Comments
 (0)