Closed kennithnichol closed 4 years ago
I have also restore the msyql service to the Travis CI configuration, since the builds were failing without it.
Thanks a bunch! I'm gonna take a deeper look at this and get back to you!
Hey @kennithnichol I've added a comment on your pull request: https://github.com/junaidbhura/fly-dynamic-image-resizer/pull/31#issuecomment-650475314
Thanks so much for your contribution, but I think it would be best to not include this functionality in this plugin. Sorry about that!
The script for adding an image size does not support passing a zero (0) for width or height. WordPress supports this behaviour to allow images to be resized and retain their aspect ratio.
The logic of
if ( ! $height || ! $width )
when$width === 0 || $height === 0
is incorrect.I propose permitting zero with an additional check for zero on those statements.