Skip to content

Commit

Permalink
Check file exists before delete
Browse files Browse the repository at this point in the history
  • Loading branch information
mnightingale committed Mar 4, 2022
1 parent 466511d commit 5f53b55
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/IlluminateSnappyPdf.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ protected function filesize($filename)
*/
protected function unlink($filename)
{
return $this->fs->delete($filename);
return $this->fileExists($filename) && $this->fs->delete($filename);
}

/**
Expand Down

0 comments on commit 5f53b55

Please sign in to comment.