Skip to content

Properly detect mime type when attaching using base64 #28

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

Merged
merged 1 commit into from
Mar 29, 2021

Conversation

simonerota
Copy link
Contributor

When attaching base64 files with AddAttachmentBase64, the private function attachB64 currently calls mime.TypeByExtension passing the whole filename instead of the extension. This PR wraps the variable with filepath.Ext as we already do in other places like attachData.

@xhit
Copy link
Owner

xhit commented Mar 29, 2021

Thanks for this fix!

@xhit xhit merged commit c1a7db7 into xhit:master Mar 29, 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

Successfully merging this pull request may close these issues.

2 participants