File tree Expand file tree Collapse file tree 3 files changed +9
-7
lines changed
Expand file tree Collapse file tree 3 files changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ import { SAFE_NO_SAVE_ARBORIST_REIFY_OPTIONS_OVERRIDES } from '../../shadow/npm/
44import type { ActualTreeResult } from './agent-fix.mts'
55
66export async function getActualTree (
7- cwd : string = process . cwd ( ) ,
7+ cwd = process . cwd ( ) ,
88) : Promise < ActualTreeResult > {
99 try {
1010 // @npmcli /arborist DOES have partial support for pnpm structured node_modules
Original file line number Diff line number Diff line change @@ -281,10 +281,11 @@ async function run(
281281 dryRun ,
282282 )
283283
284+ const processCwd = process . cwd ( )
284285 const cwd =
285- cwdOverride && cwdOverride !== 'process.cwd()'
286- ? path . resolve ( process . cwd ( ) , String ( cwdOverride ) )
287- : process . cwd ( )
286+ cwdOverride && cwdOverride !== processCwd
287+ ? path . resolve ( processCwd , String ( cwdOverride ) )
288+ : processCwd
288289
289290 // Accept zero or more paths. Default to cwd() if none given.
290291 let targets = cli . input || [ cwd ]
Original file line number Diff line number Diff line change @@ -128,10 +128,11 @@ async function run(
128128 reachEcosystems . push ( ecosystem as PURL_Type )
129129 }
130130
131+ const processCwd = process . cwd ( )
131132 const cwd =
132- cwdOverride && cwdOverride !== 'process.cwd()'
133- ? path . resolve ( process . cwd ( ) , String ( cwdOverride ) )
134- : process . cwd ( )
133+ cwdOverride && cwdOverride !== processCwd
134+ ? path . resolve ( processCwd , String ( cwdOverride ) )
135+ : processCwd
135136
136137 // Accept zero or more paths. Default to cwd() if none given.
137138 let targets = cli . input || [ cwd ]
You can’t perform that action at this time.
0 commit comments