Skip to content

Build your personal knowledge base with Trilium Notes

improve status 500 for canvas-note api/image.js

Tome156c6292b50
diff --git a/src/routes/api/image.js b/src/routes/api/image.js
index 8981c316ab..bf4e18a1eb 100644
--- a/src/routes/api/image.js
+++ b/src/routes/api/image.js
@@ -45,7 +45,7 @@ function returnImage(req, res) {
res.send(svgHtml);
});
} catch(err) {
- res.sendStatus(500);
+ res.status(500).send("there was an error parsing excalidraw to svg");
}
} else {
res.set('Content-Type', image.mime);