Blossom: add file extension by default (option to enable) #8

Open
opened 2024-08-31 12:40:25 +00:00 by sjors · 5 comments

There's ongoing discussion about whether extensions MUST be included, or if they should stay optional. But in my own experience I keep forgetting to add it. So I would prefer if it was always added. If not all users want that, it could just be a config option.

So /upload should return https://img.sprovoost.nl/78c8ac8f5f0c3d147888381ecc119e74d7c5d692bc0130bfba68306bee95e7c6.jpg instead of https://img.sprovoost.nl/78c8ac8f5f0c3d147888381ecc119e74d7c5d692bc0130bfba68306bee95e7c6

There's ongoing discussion about whether extensions `MUST` be included, or if they should stay optional. But in my own experience I keep forgetting to add it. So I would prefer if it was always added. If not all users want that, it could just be a config option. So `/upload` should return `https://img.sprovoost.nl/78c8ac8f5f0c3d147888381ecc119e74d7c5d692bc0130bfba68306bee95e7c6.jpg` instead of `https://img.sprovoost.nl/78c8ac8f5f0c3d147888381ecc119e74d7c5d692bc0130bfba68306bee95e7c6`
Author
See https://github.com/hzrd149/blossom/issues/25
sjors changed title from Add file extension by default (option to enable) to Blossom: add file extension by default (option to enable) 2024-08-31 12:40:43 +00:00
Owner

Clients should add the extension i dont see a reason why a server would return it, if kind 1 notes need the extension then thats up to the client embedding the link in the post.

Clients should add the extension i dont see a reason why a server would return it, if kind 1 notes need the extension then thats up to the client embedding the link in the post.
Kieran added the
question
label 2024-09-02 10:26:47 +00:00
Author

There's something to be said for having the client add the extension. However, even the web based upload doesn't add it.

There's something to be said for having the client add the extension. However, even the web based upload doesn't add it.

This might be only loosely related, but everything uploaded is kept in the DB as a application/octet-stream and also served as such. We would not need the extensions if proper content type would be served.

This might be misconception or maybe misconfiguration on my end, because I looked at the code and it looks like that application/octet-stream is only the default content type.

This might be only loosely related, but everything uploaded is kept in the DB as a application/octet-stream and also served as such. We would not need the extensions if proper content type would be served. This might be misconception or maybe misconfiguration on my end, because I looked at the code and it looks like that application/octet-stream is only the default content type.

I did some more testing and anything uploaded directly using the webUI works as expected. Correct content type is set and the URL works fine without extensions.

This is a client issue.

I did some more testing and anything uploaded directly using the webUI works as expected. Correct content type is set and the URL works fine without extensions. This is a client issue.
Sign in to join this conversation.
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: Kieran/void-cat-rs#8
No description provided.