New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@pnpm/hooks.read-package-hook

Package Overview
Dependencies
Maintainers
2
Versions
51
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pnpm/hooks.read-package-hook - npm Package Compare versions

Comparing version 3.0.4 to 3.0.5

lib/isIntersectingRange.d.ts

8

lib/createVersionsOverrider.js

@@ -13,3 +13,3 @@ "use strict";

const normalize_path_1 = __importDefault(require("normalize-path"));
const isSubRange_1 = require("./isSubRange");
const isIntersectingRange_1 = require("./isIntersectingRange");
function createVersionsOverrider(overrides, rootDir) {

@@ -62,4 +62,4 @@ const parsedOverrides = tryParseOverrides(overrides);

for (const [name, pref] of Object.entries(deps)) {
const versionOverride = pickMostSpecificVersionOverride(versionOverrides.filter(({ targetPkg }) => targetPkg.name === name && (0, isSubRange_1.isSubRange)(targetPkg.pref, pref))) ??
pickMostSpecificVersionOverride(genericVersionOverrides.filter(({ targetPkg }) => targetPkg.name === name && (0, isSubRange_1.isSubRange)(targetPkg.pref, pref)));
const versionOverride = pickMostSpecificVersionOverride(versionOverrides.filter(({ targetPkg }) => targetPkg.name === name && (0, isIntersectingRange_1.isIntersectingRange)(targetPkg.pref, pref))) ??
pickMostSpecificVersionOverride(genericVersionOverrides.filter(({ targetPkg }) => targetPkg.name === name && (0, isIntersectingRange_1.isIntersectingRange)(targetPkg.pref, pref)));
if (!versionOverride)

@@ -79,4 +79,4 @@ continue;

function pickMostSpecificVersionOverride(versionOverrides) {
return versionOverrides.sort((a, b) => (0, isSubRange_1.isSubRange)(b.targetPkg.pref ?? '', a.targetPkg.pref ?? '') ? -1 : 1)[0];
return versionOverrides.sort((a, b) => (0, isIntersectingRange_1.isIntersectingRange)(b.targetPkg.pref ?? '', a.targetPkg.pref ?? '') ? -1 : 1)[0];
}
//# sourceMappingURL=createVersionsOverrider.js.map
{
"name": "@pnpm/hooks.read-package-hook",
"version": "3.0.4",
"version": "3.0.5",
"description": "Creates the default package reader hook used by pnpm",

@@ -39,3 +39,3 @@ "main": "lib/index.js",

"@yarnpkg/core": "4.0.0-rc.45",
"@pnpm/hooks.read-package-hook": "3.0.4"
"@pnpm/hooks.read-package-hook": "3.0.5"
},

@@ -42,0 +42,0 @@ "funding": "https://opencollective.com/pnpm",

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