New error handling for unsupported image types#102
New error handling for unsupported image types#102buggyzap wants to merge 2 commits intoPrestaShop:devfrom
Conversation
There was a problem hiding this comment.
Hello @buggyzap ,
Thanks for the PR !
The error message is displayed twice. Could you make it so that it appears just once ?
It would also be better to have a message like so : Image format not recognized, allowed formats are: gif, jpg, jpeg, jpe, png, webp.

Thanks!
|
This pull request seems to contain new translation strings. I have summarized them below to ease up review:
(Note: this is an automated message, but answering it will reach a real human) |
Ok ty |
florine2623
left a comment
There was a problem hiding this comment.
Hello @buggyzap ,
With your PR, I can't add any slider anymore. The error message is always displayed, whether I upload a supporter or unsupported image type.
When I upload a jpg or png, or any supported format, the error is displayed once.
If I upload an unsupported image format, the error is displayed twice.
Screen.Recording.2024-07-04.at.12.00.58.mov
Could you check please ?
Thanks
|
missclick @boherm ? |
I haven't see the Florine's comment.. 😅 |
|
friendly reminder @buggyzap :D |
If we try to upload a new file that is not a valid image, no errors are shown. Backoffice returns success message and image remain the same. With this little "else" check we can track if the uploaded file was included in supported extensions and/or mimetypes.