When uploading a file (e.g. diagrams.net diagram) that's larger then the webservers max file upload size, the upload (obviously) fails. The error message is very unprecise: "An error occurred uploading the image"
Steps To Reproduce
- Find out your max file upload size limit (nginx default: 1MB)
- Find a file (e.g. image) that's larger
- Try uploading the image
- See error
Expected behavior
The error message should tell the user the reason for failure, if possible. An example could be:
' The uploaded image was too large.'
In case of a file being too large, the HTTP response code of '413 (entity too large)' can be used to detect this kind of error.
Other reasons for failure should be accounted for as well.
Screenshots
n/a
Your Configuration (please complete the following information):
- BookStack v21.04.3
- PHP Version: 7.3.27-1~deb10u1
- Hosting Method (Nginx/Apache/Docker): nginx
When uploading a file (e.g. diagrams.net diagram) that's larger then the webservers max file upload size, the upload (obviously) fails. The error message is very unprecise: "An error occurred uploading the image"
Steps To Reproduce
Expected behavior
The error message should tell the user the reason for failure, if possible. An example could be:
' The uploaded image was too large.'
In case of a file being too large, the HTTP response code of '413 (entity too large)' can be used to detect this kind of error.
Other reasons for failure should be accounted for as well.
Screenshots
n/a
Your Configuration (please complete the following information):