[fix] Crash when exporting notes (#5677)

Fixes https://github.com/koreader/koreader/issues/5609
This commit is contained in:
Mustafa Ali Mutlu
2019-12-10 01:16:45 +03:00
committed by Frans de Jonge
parent 55f3575a10
commit 7b0b5d5ba7

View File

@@ -287,7 +287,7 @@ function MyClipping:parseHistoryFile(clippings, history_file, doc_file)
title = title,
author = author,
}
self:parseHighlight(stored.highlight, stored.bookmarks, clippings.title)
self:parseHighlight(stored.highlight, stored.bookmarks, clippings[title])
end
end
@@ -318,7 +318,7 @@ function MyClipping:parseCurrentDoc(view)
title = title,
author = author,
}
self:parseHighlight(view.highlight.saved, view.ui.bookmark.bookmarks, clippings.title)
self:parseHighlight(view.highlight.saved, view.ui.bookmark.bookmarks, clippings[title])
return clippings
end