Skip to content

Commit

Permalink
Make width or height null by default
Browse files Browse the repository at this point in the history
  • Loading branch information
Nickinthebox committed May 29, 2024
1 parent 32aaab5 commit be5e7ed
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Builder.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,14 @@ public function withHttpsPrefix(): self
* generate an image url from its slug
*
* @param string $imageSlug the image slug (ie. `/2018/01/foo.jpg`)
* @param int $width the output width
* @param int $height the output height
* @param ?int $width the output width
* @param ?int $height the output height
* @param array<string, string|int> $options accept cropWidth, cropHeight or url options parameters (like `rcr`, etc.)
*/
public function buildUrl(
string $imageSlug,
int $width = 0,
int $height = 0,
?int $width = null,
?int $height = null,
array $options = []
): string {
$image = trim($imageSlug);
Expand Down

0 comments on commit be5e7ed

Please sign in to comment.