[fix, plugin] Wallabag: avoid crash when setDownloadDirectory doesn't have a touchmenu_instance (#8933)
Fixes #8930.
This commit is contained in:
1 parent
b3a9cef97b
commit
eeefc657cb
1 file changed
+8
-6
@@ -1077,12 +1077,14 @@ end
|
||||
|
||||
function Wallabag:setDownloadDirectory(touchmenu_instance)
|
||||
require("ui/downloadmgr"):new{
|
||||
onConfirm = function(path)
|
||||
logger.dbg("Wallabag: set download directory to: ", path)
|
||||
self.directory = path
|
||||
self:saveSettings()
|
||||
touchmenu_instance:updateItems()
|
||||
end,
|
||||
onConfirm = function(path)
|
||||
logger.dbg("Wallabag: set download directory to: ", path)
|
||||
self.directory = path
|
||||
self:saveSettings()
|
||||
if touchmenu_instance then
|
||||
touchmenu_instance:updateItems()
|
||||
end
|
||||
end,
|
||||
}:chooseDir()
|
||||
end
|
||||
|
||||
|
||||
Reference in new issue
Block a user