Skip to content

Commit

Permalink
Make sure photos are shrunk.
Browse files Browse the repository at this point in the history
  • Loading branch information
dracos committed Oct 14, 2024
1 parent 2597e5a commit eebbe4f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion perllib/FixMyStreet/App/Model/PhotoSet.pm
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ sub shrink_all_to_size {
$shrunk_blob = FixMyStreet::ImageMagick->new(blob => $original_blob)
->shrink_to_percentage($percent)
->as_blob;
$percent = $percent * $resize_percent;
$percent = $percent * $resize_percent / 100;
} while (length $shrunk_blob > $size_bytes);

$images[$i] = $shrunk_blob;
Expand Down

0 comments on commit eebbe4f

Please sign in to comment.