Fixed to use the title "(null)" when the page does not have any title.

This commit is contained in:
Antoni Boucher 2015-06-07 19:51:46 -04:00
parent 57a72a7120
commit c4fc5c0c43

View File

@ -103,7 +103,8 @@ class CommandDispatcher:
def _current_title(self):
"""Convenience method to get the current title."""
return self._tabbed_browser.page_title(self._current_index())
title = self._current_widget().title()
return title if title else "(null)"
def _current_widget(self):
"""Get the currently active widget from a command."""