Socket
Socket
Sign inDemoInstall

temp-write

Package Overview
Dependencies
6
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 3.0.0 to 3.1.0

13

index.js

@@ -11,4 +11,15 @@ 'use strict';

const TMP_DIR = os.tmpdir();
const tempfile = filepath => path.join(TMP_DIR, uuid.v4(), (filepath || ''));
// Workaround for https://github.com/nodejs/node/issues/11422
let _resolved;
const getTmpDir = () => {
if (!_resolved) {
_resolved = fs.realpathSync(TMP_DIR);
}
return _resolved;
};
const tempfile = filepath => path.join(getTmpDir(), uuid.v4(), (filepath || ''));
const writeStream = (filepath, input) => new Promise((resolve, reject) => {

@@ -15,0 +26,0 @@ const writable = fs.createWriteStream(filepath);

3

package.json
{
"name": "temp-write",
"version": "3.0.0",
"version": "3.1.0",
"description": "Write string/buffer/stream to a random temp file",

@@ -45,4 +45,5 @@ "license": "MIT",

"ava": "*",
"proxyquire": "^1.7.11",
"xo": "*"
}
}
SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc