diff --git a/src/calibre/gui2/tag_browser/view.py b/src/calibre/gui2/tag_browser/view.py index 29b79dc47e..b0aa64a641 100644 --- a/src/calibre/gui2/tag_browser/view.py +++ b/src/calibre/gui2/tag_browser/view.py @@ -488,7 +488,9 @@ class TagsView(QTreeView): # {{{ if len(n) > 45: n = n[:45] + '...' ans = "'" + n + "'" - return ans.replace('&', '&&') + if ans: + ans = ans.replace('&', '&&') + return ans index = self.indexAt(point) self.context_menu = QMenu(self)