You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The doc block for get_image_sizes_by_ratio() specifies that the method "Gets the first size defined for each dimension." This makes some sense if all sizes are cropped alike for a given aspect ratio, but it does mean that passing any declared image size other than the first in the image_ratio_map list causes an error because of these lines:
If this is expected behavior, the documentation should be improved to explain that regardless of the size in an aspect ratio that we want to edit, we have to pass the first declared image size in $this->image_ratio_map[$ratio].
If you should be able to pass another image size name that is present in $this->image_ratio_map[$ratio] other than $this->image_ratio_map[$ratio][0], then the get_image_sizes_by_ratio method should be amended to return a more comprehensive list, or else the $_REQUEST['size'] check should be changed to validate against the full list of supported names for a given ratio.
The text was updated successfully, but these errors were encountered:
The doc block for
get_image_sizes_by_ratio()
specifies that the method "Gets the first size defined for each dimension." This makes some sense if all sizes are cropped alike for a given aspect ratio, but it does mean that passing any declared image size other than the first in theimage_ratio_map
list causes an error because of these lines:If this is expected behavior, the documentation should be improved to explain that regardless of the size in an aspect ratio that we want to edit, we have to pass the first declared image size in
$this->image_ratio_map[$ratio]
.If you should be able to pass another image size name that is present in
$this->image_ratio_map[$ratio]
other than$this->image_ratio_map[$ratio][0]
, then theget_image_sizes_by_ratio
method should be amended to return a more comprehensive list, or else the$_REQUEST['size']
check should be changed to validate against the full list of supported names for a given ratio.The text was updated successfully, but these errors were encountered: