Skip to content
Snippets Groups Projects
Commit 28199a3d authored by Hangzhi Yu's avatar Hangzhi Yu
Browse files

Remove check for bool

parent 2e65c121
No related branches found
No related tags found
1 merge request!246Resolve "Add predicate that checks for a preference"
Pipeline #1926 passed with warnings
......@@ -73,9 +73,7 @@ def is_site_preference_set(section: str, pref: str):
@predicate(name)
def fn() -> bool:
if isinstance(get_site_preferences()[f"{section}__{pref}"], bool):
return get_site_preferences()[f"{section}__{pref}"]
return False
return bool(get_site_preferences()[f"{section}__{pref}"])
return fn
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment