Skip to content

Commit 909ae6e

Browse files
committed
trim()
1 parent ca534bd commit 909ae6e

File tree

1 file changed

+2
-2
lines changed
  • packages/app-builder-lib/src/node-module-collector

1 file changed

+2
-2
lines changed

packages/app-builder-lib/src/node-module-collector/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@ async function isPnpmProjectHoisted(rootDir: string) {
1010
const config = await exec(command, ["config", "list"], { cwd: rootDir, shell: true })
1111
const lines = config
1212
.split("\n")
13-
.map(line => line.split("="))
13+
.map(line => line.trim().split("="))
1414
.reduce<Record<string, string>>((accum, curr) => {
1515
const [key, value] = curr
1616
return {
1717
...accum,
18-
[key]: value,
18+
[key.trim()]: value.trim(),
1919
}
2020
}, {})
2121
return lines["node-linker"] === "hoisted"

0 commit comments

Comments
 (0)