File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ import { readRegistryKey } from "./windows.ts";
99import { which } from "./path.ts" ;
1010import { error , info } from "log/mod.ts" ;
1111import { fetcher } from "../command/tools/tools/chromium.ts" ;
12+ import { existsSync } from "https://deno.land/[email protected] /fs/mod.ts" ; 1213
1314// deno-lint-ignore no-explicit-any
1415let puppeteerImport : any = undefined ;
@@ -216,7 +217,7 @@ async function findChrome(): Promise<string | undefined> {
216217 programs [ i ] ,
217218 "(Default)" ,
218219 ) ;
219- if ( path ) break ;
220+ if ( path && existsSync ( path ) ) break ;
220221 }
221222
222223 // Try the HKCR key
@@ -229,7 +230,7 @@ async function findChrome(): Promise<string | undefined> {
229230 ) ;
230231 path = path ?. match ( / " ( .* ) " / ) ;
231232 path = path ? path [ 1 ] : undefined ;
232- if ( path ) break ;
233+ if ( path && existsSync ( path ) ) break ;
233234 }
234235 }
235236 }
You can’t perform that action at this time.
0 commit comments