Details
-
Bug
-
Status: Closed
-
Resolution: Fixed
-
7.0.0 M3
-
6.2.x
-
Committed
-
3
-
3
Description
Image editor is prepared to upload images.
If you try to upload a file that is not a image it fails and thows a controled exception (ImageTypeException- see UploadImageAction:177), but in the interface it is not shown.
I pressume that this is produced because the file upload is asyncronous, so a js component (LogoEditor) is reloading the popup before than the file has finish its upload process, so any exception produced in during this proccess will be hide to the user.
It's even weird, because the last succesfuly tempFile still exists so it is show to the user.
Steps to reproduce:
- Go to my account > change image
- Upload an image (image1.jpg)
- Save
- change image again
- upload a pdf
- Expected: Popup should show an error message to inform that this kind of files could not be used as images
- Current: The previously upload image is shown
Update:
The popup was actually showing an error, but it was not marked up as an error. Making it very unnoticeable. See 'file_upload_exception_screencap.png'.
I modified the LogoEditor module to use the correct alert classes. See 'file_upload_exception_screencap_fixed.png'.
As for still showing the previously uploaded image, I think this is intended behavior. So that if the user selects an image, and then selects some other invalid file type and tries again, the original is not cleared out.
Attachments
Issue Links
- is related to
-
LPS-44513 Image uploader should handle File Size Exceptions
- Closed
-
LPS-43148 Logo Editor (image_uploader) generates FileExtensionException when property "dl.file.extensions" is restricted to certain types, even if the user uploads a file with an extension allowed
- Closed
- relates
-
LPE-11742 Image editor does not display ImageTypeExceptions
-
- Closed
-