Fix AbstractTab repr() with no URL available
This commit is contained in:
parent
d9516b9c1d
commit
ee7b4256a9
@ -527,6 +527,9 @@ class AbstractTab(QWidget):
|
||||
raise NotImplementedError
|
||||
|
||||
def __repr__(self):
|
||||
url = utils.elide(self.cur_url.toDisplayString(QUrl.EncodeUnicode),
|
||||
100)
|
||||
try:
|
||||
url = utils.elide(self.cur_url.toDisplayString(QUrl.EncodeUnicode),
|
||||
100)
|
||||
except AttributeError:
|
||||
url = '<AttributeError>'
|
||||
return utils.get_repr(self, tab_id=self.tab_id, url=url)
|
||||
|
Loading…
Reference in New Issue
Block a user