Skip to content

Commit

Permalink
Merge pull request #224 from erikn69/patch-1
Browse files Browse the repository at this point in the history
PHP 8.4 tests
  • Loading branch information
Nielsvanpach authored Nov 4, 2024
2 parents d873dcf + b11bf8d commit 4fd2203
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest]
php: [8.3, 8.2, 8.1, 8.0, 7.4, 7.3]
php: [8.4, 8.3, 8.2, 8.1, 8.0, 7.4, 7.3]
dependency-version: [prefer-lowest, prefer-stable]

name: P${{ matrix.php }} - ${{ matrix.dependency-version }} - ${{ matrix.os }}
Expand Down
4 changes: 2 additions & 2 deletions src/OptimizerChain.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,11 @@ public function useLogger(LoggerInterface $log)
return $this;
}

public function optimize(string $pathToImage, string $pathToOutput = null)
public function optimize(string $pathToImage, ?string $pathToOutput = null)
{
if ($pathToOutput) {
$check = copy($pathToImage, $pathToOutput);
if($check == false) {
if ($check == false) {
throw new InvalidArgumentException("Cannot copy file");
}
$pathToImage = $pathToOutput;
Expand Down

0 comments on commit 4fd2203

Please sign in to comment.