Skip to content

Commit

Permalink
refactor: PHPStan cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
khalwat committed Mar 28, 2024
1 parent 17cac5e commit 306e598
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/imagetransforms/SharpImageTransform.php
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ public function getTransformUrl(Asset $asset, $transform)
}
$position = $yPos . '-' . $xPos;
}
if (!empty($position) && preg_match('/(top|center|bottom)-(left|center|right)/', $position)) {
if (preg_match('/(top|center|bottom)-(left|center|right)/', $position)) {
$positions = explode('-', $position);
$positions = array_diff($positions, ['center']);
// Reverse the coordinates because Sharp requires them in the "X Y" format
Expand Down

0 comments on commit 306e598

Please sign in to comment.