From 0b93b5eccb4f38df5f41847452abf749c78291c8 Mon Sep 17 00:00:00 2001 From: moanos Date: Wed, 6 Nov 2024 23:32:01 +0100 Subject: [PATCH] fix: Correct behaviour for further information = None --- src/fellchensammlung/tools/admin.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/fellchensammlung/tools/admin.py b/src/fellchensammlung/tools/admin.py index 175409c..569646b 100644 --- a/src/fellchensammlung/tools/admin.py +++ b/src/fellchensammlung/tools/admin.py @@ -76,7 +76,7 @@ def deactivate_unchecked_adoption_notices(): def deactivate_404_adoption_notices(): for adoption_notice in get_active_adoption_notices(): - if adoption_notice.further_information != "": + if adoption_notice.further_information and adoption_notice.further_information != "": if is_404(adoption_notice.further_information): adoption_notice.set_closed() logging_msg = f"Automatically set Adoption Notice {adoption_notice.id} closed as link to more information returened 404"