Open Pi2048 opened 6 years ago
Seems to be a filebrowser(_safe) issue, submitted it there: https://github.com/stephenmcd/filebrowser-safe/issues/100.
This is indeed a issue in the mezzanine filebrowser version. Your suggestion to fix it seems the best way to go.
We can 'fix' it on our end by extending the FILEBROWSER_EXTENSIONS setting: https://github.com/jonge-democraten/website/blob/98a26686e46ab6ee8f13812c455e0a0b1e40f1c8/website/settings.py#L561 with upper case versions, but that is rather ugly work-around and still does not work for mixed upper and lower case extensions (although rare).
We can also fix the issue in filebrowser-safe and submit a PR if it is not handled in time, and it is easy to fix (the comment 'Lower case is important' is a bit strange). Might be a nice way to give something back.
This was apparently fixed in a more recent version of filebrowser_safe: https://github.com/stephenmcd/filebrowser-safe/commit/761421ff719b7b673d008dd4b65ba4ac242ecd7a. Let's upgrade and see whether the issue persists.
Steps to reproduce:
It yields an error about allowed extensions. However, .jpg is accepted. We should accept all upper-, lower- and mixed-case versions of extensions that we allow.