mirror of https://github.com/status-im/codimd.git
parent
8375544dea
commit
8bf8a1aef1
|
@ -237,8 +237,8 @@ module.exports = function (sequelize, DataTypes) {
|
|||
// if no revision available
|
||||
Revision.create({
|
||||
noteId: note.id,
|
||||
lastContent: note.content,
|
||||
length: note.content.length,
|
||||
lastContent: note.content ? note.content : '',
|
||||
length: note.content ? note.content.length : 0,
|
||||
authorship: note.authorship
|
||||
}).then(function (revision) {
|
||||
Revision.finishSaveNoteRevision(note, revision, callback)
|
||||
|
|
Loading…
Reference in New Issue