diff --git a/src/get-nohoist.js b/src/get-nohoist.js index a6bd2e7..d2ca8a2 100644 --- a/src/get-nohoist.js +++ b/src/get-nohoist.js @@ -24,7 +24,7 @@ module.exports = function getNohoist(params = {}) { : getWorkspaces({ cwd }); const monorepoRoot = getMonorepoRoot({ cwd }); const packageJson = require(path.join(monorepoRoot, "package.json")); - const nohoistGlobs = packageJson.workspaces.nohoist; + const nohoistGlobs = packageJson.workspaces.nohoist || []; return nohoistGlobs .map((nohoistGlob) =>