cleanupImageExif causes an error `Unexpected byte at segment start` for specific image
MaxFedas opened this issue · comments
When I try to upload specific photo with cleanupImageExif
option on, picker throwі an error, but seems like it doesn't influence the photo uploading.
Expected Behavior
no error in browser console
Current Behavior
error Error: Unexpected byte at segment start: 0xFD (offset 0x1DE983)
appears
Possible Solution
add additional handler for such kind of error
Steps to Reproduce (for bugs)
- Save one of the images https://drive.google.com/file/d/1nvnmh0HnZFu77Ug2W8wgdulqmZ1_Y6L0, https://drive.google.com/file/d/1SZhrgHLyQGedRoatkLOfln0WrdbUbYUN
- Go https://jsfiddle.net/dark_ok/g48165j2/6/, click Select Files to Upload and chose on of this picture and click upload.
- Open console in devtools and there should be an error
Additional Screenshots
Context
It does not break anything, just unhandled error in console. How to avoid it? Seems like something is wrong with exif of those files, because witthout cleanupImageExif
option or for other image there is no such error.
Your Environment
- Version used: "filestack-js": "^3.25.0"
- Browser Name and version: Chrome Version 109.0.5414.119 (Official Build) (64-bit)
- Operating System and version (desktop or mobile): Ubuntu 22.04.1 LTS
- Link to your project: https://jsfiddle.net/dark_ok/g48165j2/6/