From cd905841e02e188d1def4752dc1cf16eca022e42 Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Tue, 26 Jul 2016 23:27:20 +0200 Subject: [PATCH] Don't log on_focus_changed warning if new is None --- qutebrowser/app.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qutebrowser/app.py b/qutebrowser/app.py index 6d7b6a3ea..295fca1fe 100644 --- a/qutebrowser/app.py +++ b/qutebrowser/app.py @@ -339,7 +339,7 @@ def _save_version(): def on_focus_changed(_old, new): """Register currently focused main window in the object registry.""" - if not isinstance(new, QWidget): + if not isinstance(new, QWidget) and new is not None: log.misc.debug("on_focus_changed called with non-QWidget {!r}".format( new))