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

Most recent release fails when orientation == 1 and checkOrientation true #64

Closed
flosell opened this issue Jan 21, 2019 · 0 comments
Closed

Comments

@flosell
Copy link

flosell commented Jan 21, 2019

I'm submitting a...


[x] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report 
[ ] Feature request
[ ] Documentation issue or request

Current behavior

Compressing fails with error Failed to load the image. when loading a JPEG in orientation 1 and checkOrientation enabled. This used to work up until commit a0c7b78e7ee1c9b261d56041f3b8273f56ebda05.

Expected behavior

Compressing succeeds without error.

Minimal reproduction of the problem with instructions

  • Use demo in docs page with default settings
  • Load an image with EXIF orientation >1 (e.g. this one) and observe compression and rotation work as expected
  • Load an image with EXIF orientation =1 (e.g. this one) and observe error

Environment


Compressor.js version: 1.0.4

Confirmed in Browsers (others not tested):
- [x] Chrome (desktop) version 71.0.3578.98
- [ ] Chrome (Android) version XX
- [ ] Chrome (iOS) version XX
- [x] Firefox version 64.0
- [x] Safari (desktop) version 12.0.2
- [ ] Safari (iOS) version XX
- [ ] IE version XX
- [ ] Edge version XX

Others:

Additional comments

  • Console shows following error: GET http://localhost:8000/docs/[object%20ArrayBuffer] 404 (File not found)
  • Before the suspected commit, url was always either set to the result of URL.createObjectURL() or arrayBufferToDataURL(). Afterwards, in the case of checkOrientation && !orientation >1 it remains unchanged; might this be the problem?
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

1 participant