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

fix(raw): use mime to chck binary types and exclude .json #2239

Merged
merged 1 commit into from
Mar 10, 2024
Merged

Conversation

pi0
Copy link
Member

@pi0 pi0 commented Mar 10, 2024

This PR resolves #2217 by explicitly checking file mimes to determine if they are binary or not.

A regression of the previous attempt in #2229 was that we were implicitly considering all .json imports are raw assets (extensions specifies what imports should be considered raw even without raw: prefix). Those changes are reverted now since we have a better check.

@pi0 pi0 added the bug Something isn't working label Mar 10, 2024
@pi0 pi0 changed the title fix(raw): use mime to chck binary types fix(raw): use mime to chck binary types and exclude .json Mar 10, 2024
@pi0 pi0 merged commit 52b65c7 into main Mar 10, 2024
4 of 5 checks passed
@pi0 pi0 deleted the fix/json branch March 10, 2024 10:12
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

Successfully merging this pull request may close these issues.

JSON file content returned as binary instead of json if sent as nested response
1 participant