Socket
Socket
Sign inDemoInstall

graceful-fs

Package Overview
Dependencies
Maintainers
1
Versions
67
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

graceful-fs - npm Package Compare versions

Comparing version 4.1.2 to 4.1.3

2

graceful-fs.js

@@ -36,2 +36,3 @@ var fs = require('fs')

// in play at the same time.
module.exports.close =
fs.close = (function (fs$close) { return function (fd, cb) {

@@ -47,2 +48,3 @@ return fs$close.call(fs, fd, function (err) {

module.exports.closeSync =
fs.closeSync = (function (fs$closeSync) { return function (fd) {

@@ -49,0 +51,0 @@ // Note that graceful-fs also retries when fs.closeSync() fails.

4

package.json
{
"name": "graceful-fs",
"description": "A drop-in replacement for fs, making various improvements.",
"version": "4.1.2",
"version": "4.1.3",
"repository": {

@@ -39,3 +39,3 @@ "type": "git",

"rimraf": "^2.2.8",
"tap": "^1.2.0"
"tap": "^5.4.2"
},

@@ -42,0 +42,0 @@ "files": [

@@ -37,1 +37,18 @@ # graceful-fs

```
## Global Patching
If you want to patch the global fs module (or any other fs-like
module) you can do this:
```javascript
// Make sure to read the caveat below.
var realFs = require('fs')
var gracefulFs = require('graceful-fs')
gracefulFs.gracefulify(realFs)
```
This should only ever be done at the top-level application layer, in
order to delay on EMFILE errors from any fs-using dependencies. You
should **not** do this in a library, because it can cause unexpected
delays in other parts of the program.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc