Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass on content preferences to source? #1

Open
RubenVerborgh opened this issue May 12, 2022 · 0 comments
Open

Pass on content preferences to source? #1

RubenVerborgh opened this issue May 12, 2022 · 0 comments

Comments

@RubenVerborgh
Copy link

Hi @Sindhu-Vasireddy,

Great start!

I noticed that the content type of the response is passed through:

let contentType = response.headers.get("content-type") || "text/plain";
contentType = parseContentType(contentType).type;


I wonder if we also could forward content preferences to the resource server.

So in this method:

public async getRepresentation(
identifier: ResourceIdentifier
): Promise<Representation> {

we can use RepresentationPreferences from
https://github.com/CommunitySolidServer/CommunitySolidServer/blob/dbdb9b424e4c4f68c19c66396064486bff93a7e4/src/storage/BaseResourceStore.ts#L18-L19

to set the Content-Type header on the request.

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

No branches or pull requests

1 participant