mirror of
https://github.com/koreader/koreader
synced 2024-10-31 21:20:20 +00:00
Merge pull request #1942 from koreader/houqp-master
bookstatus(fix): reset self.stats on init
This commit is contained in:
commit
62f07b505e
@ -50,15 +50,15 @@ local BookStatusWidget = InputContainer:new{
|
||||
status = "",
|
||||
modified = "",
|
||||
},
|
||||
stats = {
|
||||
total_time_in_sec = 0,
|
||||
performance_in_pages = {},
|
||||
pages = 0,
|
||||
}
|
||||
stats = nil
|
||||
}
|
||||
|
||||
function BookStatusWidget:init()
|
||||
self.stats.pages = self.document:getPageCount()
|
||||
self.stats = {
|
||||
total_time_in_sec = 0,
|
||||
performance_in_pages = {},
|
||||
pages = self.document:getPageCount(),
|
||||
}
|
||||
self:getStatisticsSettings()
|
||||
if self.settings then
|
||||
self.summary = self.settings:readSetting("summary")
|
||||
|
Loading…
Reference in New Issue
Block a user