mirror of
https://github.com/kovidgoyal/calibre.git
synced 2026-05-28 17:52:34 -04:00
Fix #976727 (Right-click error)
This commit is contained in:
@@ -177,7 +177,7 @@ class EditAuthorsDialog(QDialog, Ui_EditAuthorsDialog):
|
||||
ca.triggered.connect(self.paste_from_clipboard)
|
||||
m.addSeparator()
|
||||
|
||||
if self.context_item.column() == 0:
|
||||
if self.context_item is not None and self.context_item.column() == 0:
|
||||
ca = m.addAction(_('Copy to author sort'))
|
||||
ca.triggered.connect(self.copy_au_to_aus)
|
||||
else:
|
||||
|
||||
@@ -108,6 +108,9 @@ class UserProfiles(ResizableDialog, Ui_Dialog):
|
||||
|
||||
def show_recipe_files(self, *args):
|
||||
bdir = os.path.dirname(custom_recipes.file_path)
|
||||
if not os.path.exists(bdir):
|
||||
return error_dialog(self, _('No recipes'),
|
||||
_('No custom recipes created.'), show=True)
|
||||
open_local_file(bdir)
|
||||
|
||||
def break_cycles(self):
|
||||
|
||||
Reference in New Issue
Block a user