-
-
Notifications
You must be signed in to change notification settings - Fork 311
Closed
Description
At my company we use a modified version of npm that doesn't write resolved
or from
fields in package-lock. It does have the version field. Is there any reason not to fall back to version
if either of these fields don't exist?
patch-package/src/getPackageResolution.ts
Lines 94 to 97 in bc92d4f
return ( | |
relevantStackEntry.dependencies[packageDetails.name].resolved || | |
relevantStackEntry.dependencies[packageDetails.name].from | |
) |
Locally I modified this line to be
return (
relevantStackEntry.dependencies[packageDetails.name].resolved ||
relevantStackEntry.dependencies[packageDetails.name].from ||
relevantStackEntry.dependencies[packageDetails.name].version
)
and it started working. Otherwise it writes out an empty package.json and doesn't install anything.
Metadata
Metadata
Assignees
Labels
No labels