-
Bug
-
Resolution: Unresolved
-
Neutral
-
None
-
3.4.2
info.magnolia.imaging.operations.cropresize.Size provides the method
maxSizeComplyingWithSourceRatio. In my case, I set the width to 400. The acutal image has a resolution of 1920x1200, so it needs to get resized. If you not set the height in your image variation (it is an optional value), then the maxHeight will result in 0. According to my debugger, this results in a maxWidth 400, maxHeight 0, sourceRatio 1.6, tentativeWidth 400 and tentativeHeight 250. There is a check on line 94, which checks if the tentativeHeight is equals or smaller than the maxHeight. From my point of view, there is a check missing, if the maxHeight is 0. This would prevent in my case, that the size is calculated in the else block based on the width, which is 0, and causes in the end a 500 response, with no image shown.