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: support more uncommon file types for attachments #520

Merged
merged 1 commit into from
Aug 21, 2024

Conversation

Fredx87
Copy link
Contributor

@Fredx87 Fredx87 commented Aug 21, 2024

Description

It seems that the fix implemented in #514 was not enough to solve the issue with attachment uploads of uncommon file types. We decided to not pass the Content-Type and let the backend set it, but the backend is still returning a 406 response for some file types (for example for a .pcap file).

The only fix we can implement on our side is to use a library to determine the correct mime type based on the file extension. I used the mime library, which adds ~10K to the shared-bundle.js file when gzipped.

Checklist

  • 📗 all commit messages follow the conventional commits standard
  • ⬅️ changes are compatible with RTL direction
  • ♿ Changes to the UI are tested for accessibility and compliant with WCAG 2.1.
  • 📝 changes are tested in Chrome, Firefox, Safari and Edge
  • 📱 changes are responsive and tested in mobile
  • 👍 PR is approved by @zendesk/vikings

@Fredx87 Fredx87 requested a review from a team as a code owner August 21, 2024 13:45
@Fredx87 Fredx87 force-pushed the gianluca/GG-3798-attachments-fix branch from 99d7106 to 9dca6e3 Compare August 21, 2024 13:54
@Fredx87 Fredx87 force-pushed the gianluca/GG-3798-attachments-fix branch from 9dca6e3 to 97d1fa3 Compare August 21, 2024 13:54
@Fredx87 Fredx87 merged commit c6eee62 into master Aug 21, 2024
5 checks passed
@Fredx87 Fredx87 deleted the gianluca/GG-3798-attachments-fix branch August 21, 2024 14:01
@zd-svc-github-copenhagen-theme
Copy link
Collaborator

🎉 This PR is included in version 4.0.11 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

3 participants