FIX: executablePath() return path even on headful

This commit is contained in:
Lucas Buzzo 2022-11-04 10:04:53 -03:00
parent 7b58b551cf
commit eeef9b1c18
1 changed files with 0 additions and 4 deletions

View File

@ -180,10 +180,6 @@ class Chromium {
* If not running on AWS Lambda nor Google Cloud Functions, `null` is returned instead. * If not running on AWS Lambda nor Google Cloud Functions, `null` is returned instead.
*/ */
static get executablePath(): Promise<string> { static get executablePath(): Promise<string> {
if (Chromium.headless !== true) {
return Promise.resolve(null);
}
if (existsSync('/tmp/chromium') === true) { if (existsSync('/tmp/chromium') === true) {
for (const file of readdirSync('/tmp')) { for (const file of readdirSync('/tmp')) {
if (file.startsWith('core.chromium') === true) { if (file.startsWith('core.chromium') === true) {