From c4762d92f7ed0fc9c084a4b8b8cc52485d9a006b Mon Sep 17 00:00:00 2001 From: tobi-wan-kenobi Date: Tue, 7 Apr 2020 21:00:55 +0200 Subject: [PATCH] [core/theme] slight refactoring --- core/theme.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/core/theme.py b/core/theme.py index e32c70a..778ea26 100644 --- a/core/theme.py +++ b/core/theme.py @@ -88,10 +88,9 @@ class Theme(object): def get(self, key, widget=None, default=None): if not widget: widget = core.widget.Widget('') - if isinstance(widget, str): - # special handling - if widget == 'previous': - return self.__previous.get(key, None) + # special handling + if widget == 'previous': + return self.__previous.get(key, None) value = default