got rid of simple-node-logger in favor of simple custom logger

This commit is contained in:
zadam
2020-06-23 13:38:27 +02:00
parent 22302e8200
commit b245b249d3
4 changed files with 89 additions and 24 deletions

View File

@@ -123,7 +123,12 @@ class Note extends Entity {
throw new Error(`Cannot set null content to note ${this.noteId}`);
}
content = Buffer.isBuffer(content) ? content : Buffer.from(content);
if (this.isStringNote()) {
content = content.toString();
}
else {
content = Buffer.isBuffer(content) ? content : Buffer.from(content);
}
// force updating note itself so that dateModified is represented correctly even for the content
this.forcedChange = true;