small refactorings

This commit is contained in:
zadam
2023-06-29 22:10:13 +02:00
parent f4ec4e58c7
commit 48029cea7c
37 changed files with 95 additions and 155 deletions

View File

@@ -105,8 +105,7 @@ function importEnex(taskContext, file, parentNote) {
}
saxStream.on("error", e => {
// unhandled errors will throw, since this is a proper node
// event emitter.
// unhandled errors will throw, since this is a proper node event emitter.
log.error(`error when parsing ENEX file: ${e}`);
// clear the error
this._parser.error = null;
@@ -322,7 +321,7 @@ function importEnex(taskContext, file, parentNote) {
content += imageLink;
}
} catch (e) {
log.error(`error when saving image from ENEX file: ${e}`);
log.error(`error when saving image from ENEX file: ${e.message}`);
createFileNote();
}
} else {