lostdesign/teamotes

Fix static image mime type

lostdesign opened this issue · 0 comments

Currently the image mime type is hardcoded to image/png but should rather be dynamic based on the file that got clicked on. Perhaps related to #9 as electrons api includes a get filetype method.

Check the following line:

const blob = this.b64ToBlob(buffer, 'image/png', 512)

See https://nodejs.org/api/fs.html for reference, there should be file.extension or something along those lines.