Skip to content

Commit

Permalink
also return the result of originalOpen
Browse files Browse the repository at this point in the history
  • Loading branch information
jloleysens committed Nov 8, 2021
1 parent 2d48c6c commit 9bbd987
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/readfilecontext.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ exports.getReadFileContextPrototype = function() {
let proto;
fsBinding.open = (_path, _flags, _mode, req) => {
proto = Object.getPrototypeOf(req.context);
originalOpen.apply(fsBinding, [_path, _flags, _mode, req]);
return originalOpen.apply(fsBinding, [_path, _flags, _mode, req]);
};

fs.readFile('/ignored.txt', () => {});
Expand Down

0 comments on commit 9bbd987

Please # to comment.