mirror of
https://github.com/zadam/trilium.git
synced 2025-06-06 18:08:33 +02:00
defensive check, #1736
This commit is contained in:
parent
12b468d3dc
commit
e1a16b4a9f
@ -106,7 +106,7 @@ function processContent(images, note, content) {
|
|||||||
for (const {src, dataUrl, imageId} of images) {
|
for (const {src, dataUrl, imageId} of images) {
|
||||||
const filename = path.basename(src);
|
const filename = path.basename(src);
|
||||||
|
|
||||||
if (!dataUrl.startsWith("data:image")) {
|
if (!dataUrl || !dataUrl.startsWith("data:image")) {
|
||||||
log.info("Image could not be recognized as data URL:", dataUrl.substr(0, Math.min(100, dataUrl.length)));
|
log.info("Image could not be recognized as data URL:", dataUrl.substr(0, Math.min(100, dataUrl.length)));
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user