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

"Undefined array key 1" when given large single trim parameter #218

Open
jordanade opened this issue Apr 15, 2024 · 1 comment
Open

"Undefined array key 1" when given large single trim parameter #218

jordanade opened this issue Apr 15, 2024 · 1 comment

Comments

@jordanade
Copy link
Contributor

jordanade commented Apr 15, 2024

This filename:
Hnr4t2QO4ugMstGTejDqUAkSyBXF2GlQozIjfs76-_x138-resize-trim(66218942676).png
generated this error:
Undefined array key 1
on this line:
line 109: list($x1, $y1, $x2, $y2) = $coords;
in this file:
/vendor/bkwld/croppa/src/Image.php

For these kinds of invalid or out-of-range inputs, can we return, say, 422 Unprocessable Entity?

@sdebacker
Copy link
Collaborator

Feel free to make a PR, with tests.

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

No branches or pull requests

2 participants