Fix uploading higher-than-wide GIF profile picture with libvips enabled (#32911)
This commit is contained in:
parent
0838cf1e05
commit
f1ef7b5b43
3 changed files with 9 additions and 1 deletions
|
@ -52,6 +52,7 @@ module Paperclip
|
|||
# implement. If cropping ever becomes necessary for other situations, this will
|
||||
# need to be expanded.
|
||||
crop_width = crop_height = [target_width, target_height].min if @target_geometry&.square?
|
||||
crop_width = crop_height = "'min(iw,ih)'" if crop_width == 'ih'
|
||||
|
||||
filter = begin
|
||||
if @crop
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue