upload
upload copied to clipboard
Really bad UX when not allowed to download file, in particular in Firefox
- flagrow/upload extension version: 0.6.0
- flarum version: 0.1.0-beta.7.1
- upload adapter causing issues: irrelevant (tested with local)
- mimetype configurations: irrelevant
If for example guests are denied download ability but some public posts include downloads, the experience is awful. The download button offer no indication of the permission and the API download call returns a 401 error, but as the payload is json the browsers have different ways of rendering it to the user.
Chrome simply displays the JSON payload, not too bad:
But Firefox shows its own error page, which seems to be the same for 404 or 401
(Screenshot in French, reads "File not found")
This is very confusing, in particular when debugging. The download endpoint should probably return some text/html response in case of 401 errors