calibre: fix attempt to index path_entry (#9837)

Fixes #9836
reviewable/pr9839/r1
Martín Fernández 1 year ago committed by GitHub
parent 3ef2811e59
commit ee94a575f1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -416,7 +416,7 @@ function CalibreSearch:browse(option)
self.search_menu.paths = {}
self.search_menu.onReturn = function ()
local path_entry = table.remove(self.search_menu.paths)
local page = path_entry.page or 1
local page = path_entry and path_entry.page or 1
if #self.search_menu.paths < 1 then
-- If nothing is left in paths we switch to original items and title
self.search_menu.paths = {}

Loading…
Cancel
Save