Statistics: AnnotationsModified event naming

reviewable/pr11563/r16
hius07 1 month ago committed by GitHub
parent 626392f17b
commit 8837336922
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -2727,13 +2727,13 @@ function ReaderStatistics:onCloseDocument()
self:insertDB()
end
function ReaderStatistics:onAnnotationsModified(diff)
function ReaderStatistics:onAnnotationsModified(annotations)
if self.settings.is_enabled then
if diff.highlights then
self.data.highlights = self.data.highlights + diff.highlights
if annotations.nb_highlights_added then
self.data.highlights = self.data.highlights + annotations.nb_highlights_added
end
if diff.notes then
self.data.notes = self.data.notes + diff.notes
if annotations.nb_notes_added then
self.data.notes = self.data.notes + annotations.nb_notes_added
end
end
end

Loading…
Cancel
Save