|
@@ -209,10 +209,6 @@ export default function UserInteractions(opts) {
|
|
|
}
|
|
|
if (req.body.playlistuuid) {
|
|
|
db.execute("SELECT owner FROM playlist WHERE uuid = ?", [req.body.playlistuuid], async function (err, result) {
|
|
|
- if (["image/png", "image/webp", "image/jpeg","image/jpg", "image/bmp"].indexOf((await detectBufferMime(Buffer.from(Object.values(req.body.tmb.data))))) === -1) {
|
|
|
- res.set(cwh).status(500).json({code: 500, R: "ILLEGAL IMAGE"})
|
|
|
- return;
|
|
|
- }
|
|
|
if (result[0].owner === req.session.uuid) {
|
|
|
let uuid = crypto.randomUUID();
|
|
|
fs.writeFileSync("tmp/"+uuid, Buffer.from(Object.values(req.body.tmb.data)));
|