Skip to content
This repository was archived by the owner on Dec 31, 2020. It is now read-only.

What Content-Type to return on the attachment endpoint #218

Open
quentez opened this issue Jan 30, 2014 · 0 comments
Open

What Content-Type to return on the attachment endpoint #218

quentez opened this issue Jan 30, 2014 · 0 comments

Comments

@quentez
Copy link
Contributor

quentez commented Jan 30, 2014

In it's current form, the attachment endpoint only takes an entity and a digest as parameters. This means it just references a file and not a specific post having that file as attachment. The problem this creates is that different posts can reference the same attachment with different content-type, in such situation: what Content-Type should the attachment endpoint return?

From what I've been told, the current rule would be to return the Content-Type of the most recent post. But this is problematic: what if two apps use the same file with different content-type. The app that created the post first would now receive the wrong headers when retrieving files from the attachment endpoint.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant