ReaderHighlight: Don't try to close a non-existent widget in onClose
This commit is contained in:
1 parent
c529c1cce3
commit
5bd78ab3b4
1 file changed
+4
-2
@@ -2208,8 +2208,10 @@ function ReaderHighlight:onSaveSettings()
|
||||
end
|
||||
|
||||
function ReaderHighlight:onClose()
|
||||
UIManager:close(self.highlight_dialog)
|
||||
self.highlight_dialog = nil
|
||||
if self.highlight_dialog then
|
||||
UIManager:close(self.highlight_dialog)
|
||||
self.highlight_dialog = nil
|
||||
end
|
||||
-- clear highlighted text
|
||||
self:clear()
|
||||
end
|
||||
|
||||
Reference in new issue
Block a user