Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Bob van de Vijver <bobvandevijver@users.noreply.github.com>
  • Loading branch information
tobias-93 and bobvandevijver authored Feb 13, 2024
1 parent 591a3d1 commit 048d3f8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
8 changes: 4 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@
}
],
"require": {
"php": "^8.2",
"php": ">=8.2",
"ext-gd": "*",
"ext-random": "*",
"symfony/filesystem": ">=5.4.35",
"symfony/finder": ">=5.4.35",
"symfony/process": ">=5.4.35"
"symfony/filesystem": "^5.4 || ^6.4 || ^7.0",
"symfony/finder": "^5.4 || ^6.4 || ^7.0",
"symfony/process": "^5.4 || ^6.4 || ^7.0"
},
"require-dev": {
"pestphp/pest": "^1.21"
Expand Down
3 changes: 1 addition & 2 deletions src/Pdf.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,7 @@ public function getNumberOfPages(): int
{
if ($this->numberOfPages === null) {
$this->prepareImages();
$finder = new Finder();
$this->numberOfPages = $finder->in($this->cacheDir)->name('*.png')->count();
$this->numberOfPages = (new Finder())->in($this->cacheDir)->name('*.png')->count();
}

return $this->numberOfPages;
Expand Down

0 comments on commit 048d3f8

Please sign in to comment.