Fix "Move current book to archive" (#11321)

updateItemByPath has recently been replaced with updateItem in both
readhistory and readcollection.

Fixes: aabd6d7a26 ("File browser, Collection: improve group actions (#11178)")
Fixes: https://github.com/koreader/koreader/issues/11320
reviewable/pr11327/r1
Tomáš Janoušek 4 months ago committed by GitHub
parent 5d2a441064
commit ccbfbabb25
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -103,8 +103,8 @@ function MoveToArchive:onMoveToArchive(do_copy)
else
text = _("Book moved.\nDo you want to open it from the archive folder?")
FileManager:moveFile(document_full_path, self.archive_dir_path)
require("readhistory"):updateItemByPath(document_full_path, dest_file) -- (will update "lastfile" if needed)
require("readcollection"):updateItemByPath(document_full_path, dest_file)
require("readhistory"):updateItem(document_full_path, dest_file) -- (will update "lastfile" if needed)
require("readcollection"):updateItem(document_full_path, dest_file)
end
DocSettings.updateLocation(document_full_path, dest_file, do_copy)
UIManager:show(ConfirmBox:new{

Loading…
Cancel
Save