fix corepack detection for package manager version determination (#11596)

The previous logic was checking for the env var `ENABLE_EXPERIMENTAL_COREPACK` to determine if corepack was being used by a project. However, this value only means that the build system should consider corepack, not that it's actively being used.

We need to check that flag AND the existence of a `packageManager` property in the project's `package.json`.
This commit is contained in:
Sean Massa
2024-05-15 14:25:01 -05:00
committed by GitHub
parent 41c44d6594
commit ccd7eb1fb7
9 changed files with 95 additions and 23 deletions

View File

@@ -0,0 +1,5 @@
---
"@vercel/build-utils": minor
---
fix corepack detection for package manager version determination