Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@pnpm/fs-locker

Package Overview
Dependencies
Maintainers
3
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pnpm/fs-locker - npm Package Compare versions

Comparing version 3.0.0 to 3.0.1

2

lib/index.d.ts

@@ -5,4 +5,4 @@ export default function withLock<T>(dir: string, opts: {

whenLocked?: () => void;
}): Promise<(() => Promise<{}>) & {
}): Promise<(() => Promise<void>) & {
sync: () => void;
}>;

@@ -21,4 +21,22 @@ "use strict";

await lockfile.lock(lockFilename, { realpath: false, stale: opts.stale });
const unlockThis = () => lockfile.unlock(lockFilename, { realpath: false });
unlockThis['sync'] = () => lockfile.unlockSync(lockFilename, { realpath: false }); // tslint:disable-line
async function unlockThis() {
try {
await lockfile.unlock(lockFilename, { realpath: false });
}
catch (err) {
// We don't care if the folder was not locked or already unlocked
if (err.code !== 'ENOTACQUIRED')
throw err;
}
}
unlockThis['sync'] = function unlockSync() {
try {
lockfile.unlockSync(lockFilename, { realpath: false });
}
catch (err) {
// We don't care if the folder was not locked or already unlocked
if (err.code !== 'ENOTACQUIRED')
throw err;
}
};
return unlockThis;

@@ -25,0 +43,0 @@ }

{
"name": "@pnpm/fs-locker",
"version": "3.0.0",
"version": "3.0.1",
"description": "An fs locker for pnpm",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

Sorry, the diff of this file is not supported yet

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