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

CSV mimetypes are not just "text/csv" #1

Closed
bondt opened this issue Feb 8, 2021 · 2 comments
Closed

CSV mimetypes are not just "text/csv" #1

bondt opened this issue Feb 8, 2021 · 2 comments

Comments

@bondt
Copy link

bondt commented Feb 8, 2021

My browser reports CSV files as mimetype application/vnd.ms-excel. This fails in the isCSV function. Would you mind adding that?

if (file.type == "text/csv" || !file.type) return true;

So replace that function with the following:

export function isCSV(file){
  if (file.type == "text/csv" || file.type == "application/vnd.ms-excel" || !file.type) return true;
}

Thanks!

@leo-holanda
Copy link
Owner

Hey! Thanks for the issue! I changed the code, if some bug appears again please let me know!

@leo-holanda leo-holanda reopened this Feb 9, 2021
@bondt
Copy link
Author

bondt commented Feb 11, 2021

You're welcome! Haven't had a lot of time to check it out further, but it works now.

@bondt bondt closed this as completed Feb 11, 2021
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

2 participants