From 1ee3acca0f97a4634958a9e8170322ff313a9efb Mon Sep 17 00:00:00 2001 From: Hanne Moa Date: Thu, 23 Nov 2023 12:19:35 +0100 Subject: [PATCH] Change if-statement to boolean expression Co-authored-by: Morten Brekkevold --- python/nav/util.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/python/nav/util.py b/python/nav/util.py index b75162c47b..e6ef429014 100644 --- a/python/nav/util.py +++ b/python/nav/util.py @@ -549,6 +549,4 @@ def check_log_level(logger, loglevel): logger.info("%s", expensive_function()) """ level = logger.getEffectiveLevel() - if level <= loglevel: - return True - return False + return level <= loglevel