From 80cd8af9567bf2ddeb017ea738de0adb4fba2543 Mon Sep 17 00:00:00 2001 From: Lukas Fleischer Date: Mon, 6 Nov 2023 15:45:08 -0500 Subject: calcurse-caldav: use isinstance() instead of comparing types Signed-off-by: Lukas Fleischer --- contrib/caldav/calcurse-caldav.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/caldav/calcurse-caldav.py b/contrib/caldav/calcurse-caldav.py index 8cccdf7..5efd306 100755 --- a/contrib/caldav/calcurse-caldav.py +++ b/contrib/caldav/calcurse-caldav.py @@ -77,7 +77,7 @@ class Config: for key, val in config.items(sec): if key not in self._map[sec]: die('Unexpected config key in section {}: {}'.format(sec, key)) - if type(self._map[sec][key]) == bool: + if isinstance(self._map[sec][key], bool): self._map[sec][key] = config.getboolean(sec, key) else: self._map[sec][key] = val -- cgit v1.2.3-70-g09d2