mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
Avoid settings double save when leaving Reader (#3131)
This commit is contained in:
@@ -547,7 +547,11 @@ end
|
||||
|
||||
function ReaderUI:onClose()
|
||||
logger.dbg("closing reader")
|
||||
self:saveSettings()
|
||||
-- if self.dialog is us, we'll have our onFlushSettings() called
|
||||
-- by UIManager:close() below, so avoid double save
|
||||
if self.dialog ~= self then
|
||||
self:saveSettings()
|
||||
end
|
||||
if self.document ~= nil then
|
||||
logger.dbg("closing document")
|
||||
self:notifyCloseDocument()
|
||||
|
||||
Reference in New Issue
Block a user