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

Expedition image resize has jpg hardcoded #526

Open
cdausmus opened this issue Aug 9, 2022 · 0 comments
Open

Expedition image resize has jpg hardcoded #526

cdausmus opened this issue Aug 9, 2022 · 0 comments
Assignees

Comments

@cdausmus
Copy link
Collaborator

cdausmus commented Aug 9, 2022

When uploading an expedition image that is not a jpg, an error occurs:

2022-08-09 09:44:14.056 ERROR --- [nio-8080-exec-5] au.org.ala.volunteer.ProjectService      : Could not check and resize expedition image for Testing Field Notes

javax.imageio.IIOException: Invalid argument to native writeImage
        at com.sun.imageio.plugins.jpeg.JPEGImageWriter.writeImage(Native Method)
        at com.sun.imageio.plugins.jpeg.JPEGImageWriter.writeOnThread(JPEGImageWriter.java:1067)
        at com.sun.imageio.plugins.jpeg.JPEGImageWriter.write(JPEGImageWriter.java:363)
        at javax.imageio.ImageWriter.write(ImageWriter.java:615)
        at javax.imageio.ImageIO.doWrite(ImageIO.java:1622)
        at javax.imageio.ImageIO.write(ImageIO.java:1548)
        at javax.imageio.ImageIO$write$1.call(Unknown Source)
        at au.org.ala.volunteer.ProjectService.$tt__checkAndResizeExpeditionImage(ProjectService.groovy:656)

Allow other image formats (png etc) and remove hard coding.

@cdausmus cdausmus self-assigned this Aug 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant