Final minor cleanup for previous PR

This commit is contained in:
Kovid Goyal 2023-03-31 13:38:32 +05:30
parent 5d6664b002
commit 00832ca25b
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C
2 changed files with 2 additions and 3 deletions

View File

@ -680,7 +680,5 @@ class TagListEditor(QDialog, Ui_TagListEditor):
self.table.sortByColumn(2, Qt.SortOrder(self.was_order)) self.table.sortByColumn(2, Qt.SortOrder(self.was_order))
def accepted(self): def accepted(self):
self.links = {} self.links = {self.table.item(r, 0).text():self.table.item(r, 3).text() for r in range(self.table.rowCount())}
for r in range(0, self.table.rowCount()):
self.links[self.table.item(r, 0).text()] = self.table.item(r, 3).text()
self.save_geometry() self.save_geometry()

View File

@ -698,6 +698,7 @@ class Main(MainWindow, MainWindowMixin, DeviceMixin, EmailMixin, # {{{
library_id = decode_library_id(library_id) library_id = decode_library_id(library_id)
library_path = self.library_broker.path_for_library_id(library_id) library_path = self.library_broker.path_for_library_id(library_id)
if library_path is None: if library_path is None:
prints('Ignoring unknown library id', library_id, file=sys.stderr)
return return
try: try:
book_id = int(book_id) book_id = int(book_id)