mirror of
https://github.com/zadam/trilium.git
synced 2025-03-01 14:22:32 +01:00
support image/jpg as well, closes #2103
This commit is contained in:
parent
cfcc34fa8e
commit
5f22864a93
@ -34,7 +34,7 @@ function uploadImage(req) {
|
|||||||
return [404, `Note ${noteId} doesn't exist.`];
|
return [404, `Note ${noteId} doesn't exist.`];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!["image/png", "image/jpeg", "image/gif", "image/webp", "image/svg+xml"].includes(file.mimetype)) {
|
if (!["image/png", "image/jpg", "image/jpeg", "image/gif", "image/webp", "image/svg+xml"].includes(file.mimetype)) {
|
||||||
return [400, "Unknown image type: " + file.mimetype];
|
return [400, "Unknown image type: " + file.mimetype];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user