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

File blueprint: error when create/format option is set and document is uploaded #6268

Closed
JerikoOne opened this issue Feb 14, 2024 · 0 comments · Fixed by #6359
Closed

File blueprint: error when create/format option is set and document is uploaded #6268

JerikoOne opened this issue Feb 14, 2024 · 0 comments · Fixed by #6359
Assignees
Labels
type: bug 🐛 Is a bug; fixes a bug
Milestone

Comments

@JerikoOne
Copy link

Description

When a file blueprint has the format option set so that images get converted to another format, uploading a PDF results in an error imagecreatefromstring(): Data is not in a recognized format . The uploaded file is corrupt due to the conversion process.

Expected behavior
Images should be converted to the format defined in the blueprint. Any other file should be uploaded as is.

Screenshots
image
image

To reproduce

  1. Create a new file blueprint or use default file blueprint.
  2. Add the following properties to the blueprint:
create:
  format: webp
  1. Upload a PDF using that blueprint
  2. See error

Your setup

Kirby 4.0.1 up to 4.1

Console output
image
First error while uploading. Second error while trying to get a thumbnail for the uploaded PDF that doesn't exist.

Your system (please complete the following information)

  • Device: Macbook
  • OS: macOS
  • Browser: Firefox
  • Version: 122.01

Additional context

@distantnative distantnative added the type: bug 🐛 Is a bug; fixes a bug label Mar 23, 2024
@distantnative distantnative self-assigned this Mar 23, 2024
@distantnative distantnative added this to the 4.2.0 milestone Mar 23, 2024
@distantnative distantnative linked a pull request Mar 23, 2024 that will close this issue
5 tasks
@bastianallgeier bastianallgeier modified the milestones: 4.2.0, 4.2.x Mar 27, 2024
@distantnative distantnative modified the milestones: 4.2.x, 4.3.0 May 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug 🐛 Is a bug; fixes a bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants