| Total Complexity | 5 |
| Total Lines | 31 |
| Duplicated Lines | 0 % |
| Coverage | 92.31% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 14 | class ImageResizer |
||
| 15 | { |
||
| 16 | private const CACHE_IMAGE_PATH = 'data/cache/images/'; |
||
| 17 | |||
| 18 | 18 | public function __construct(private readonly ImagineInterface $imagine) |
|
| 20 | } |
||
| 21 | |||
| 22 | /** |
||
| 23 | * Resize image as JPG or WEBP and return the path to the resized version. |
||
| 24 | */ |
||
| 25 | 18 | public function resize(Image $image, int $maxHeight, bool $useWebp): string |
|
| 47 |