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

api: allow images to be properly proxied to backend #218

Open
limwa opened this issue Jul 20, 2023 · 0 comments
Open

api: allow images to be properly proxied to backend #218

limwa opened this issue Jul 20, 2023 · 0 comments
Labels
bug Something isn't working
Milestone

Comments

@limwa
Copy link
Member

limwa commented Jul 20, 2023

          > Also, I know that it is out of the scope of this PR but won't this line (https://github.com/NIAEFEUP/website-niaefeup-frontend/pull/215/files#diff-4bcda89884a979801f8a542290893a21e5213fc48218ec305b5434ef11e70ddaR6) cause an error when the request body is, for instance, an image?

I am not sure that it would cause an error (did a quick search and the docs do not appear to mention that), maybe it will simply be a utf-8 string representation of the bytes.
I do agree that that may not be the best way to handle those cases, feel free to open an issue about that.

Originally posted by @bdmendes in #215 (comment)


The change should be pretty simple. Instead of using the text method, we can use the arrayBuffer method and pipe that to the next fetch. Use of streams should also be investigated.

@MRita443 MRita443 added the bug Something isn't working label Nov 21, 2024
@MRita443 MRita443 added this to the Website MVP milestone Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants