Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[5.4] Suppress getimagesize() warnings #17944

Merged
merged 2 commits into from
Feb 16, 2017
Merged

[5.4] Suppress getimagesize() warnings #17944

merged 2 commits into from
Feb 16, 2017

Conversation

adamwathan
Copy link
Contributor

getimagesize will fail with a notice on files smaller than 12 bytes.
This ends up becoming an ErrorException which is pretty annoying.

Suppressing the warning is enough to still end up with a false result
which will fail the validation gracefully instead of grueing up your
stew.

`getimagesize` will fail with a notice on files smaller than 12 bytes.
This ends up becoming an ErrorException which is pretty annoying.

Suppressing the warning is enough to still end up with a `false` result
which will fail the validation gracefully instead of grueing up your
stew.
@taylorotwell taylorotwell merged commit 6f13147 into laravel:5.4 Feb 16, 2017
@GrahamCampbell GrahamCampbell changed the title Suppress getimagesize() warnings [5.4] Suppress getimagesize() warnings Feb 16, 2017
taylorotwell pushed a commit that referenced this pull request Feb 18, 2017
* Suppress getimagesize() warnings

Backport of #17944.

`getimagesize` will fail with a notice on files smaller than 12 bytes.
This ends up becoming an ErrorException which is pretty annoying.

Suppressing the warning is enough to still end up with a `false` result
which will fail the validation gracefully instead of grueing up your
stew.

* Proper float comparison in ratio validation

* Convert fixtures to PNG format

* Add test for validation of ratio with no fractional part
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants