Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
DaanDeSmedt committed Jul 31, 2020
2 parents 10f234f + a9b1f52 commit 468f81e
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/HeadlessChrome.php
Original file line number Diff line number Diff line change
Expand Up @@ -132,11 +132,13 @@ public function setUrl($url)
/**
* Set the directory for render output (PDF / Screenshot)
* @param String $directory
* @param int $mode
* @param bool $recursive
*/
public function setOutputDirectory($directory)
public function setOutputDirectory($directory, $mode = 0777, $recursive = false)
{
if (!file_exists($directory) || !realpath($directory)) {
@mkdir($directory);
@mkdir($directory, $mode, $recursive);
}
$this->outputDirectory = realpath(trim($directory));
}
Expand Down

0 comments on commit 468f81e

Please sign in to comment.