Skip to content

Commit

Permalink
fix: change permissions to chromedriver binary
Browse files Browse the repository at this point in the history
  • Loading branch information
asciito committed Nov 8, 2023
1 parent 18b31f2 commit fc66cee
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions app/GoogleDownloadable.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,19 +62,21 @@ public function download(int $component, string $to, string $platform, bool $unz
if ($component & static::BROWSER) {
$url = $this->getChromeBrowserURL($platform);
$filename = join_paths($to, Str::afterLast($url, '/'));

download($url, $filename);

$unzip && unzip($filename);
}

if ($component & static::DRIVER) {
$url = $this->getChromeDriverURL($platform);
$filename = join_paths($to, Str::afterLast($url, '/'));
}

download($url, $filename);

download($url, $filename);
if ($unzip) {
unzip($filename);

$unzip && unzip($filename);
if ($component & static::DRIVER) {
chmod(join_paths(Str::beforeLast($filename, '.'), 'chromedriver'), 0555);
}
}
}

Expand Down

0 comments on commit fc66cee

Please sign in to comment.