From 8cb808f61347b76ed2db0c45151794c97b2af300 Mon Sep 17 00:00:00 2001 From: Oliver Date: Fri, 14 Nov 2025 08:26:24 +1100 Subject: [PATCH] Bug fix for loading boolean settings (#10826) - Do not just cast to bool - The string "False" casts to True in this case - Use the function that supports strings --- src/backend/InvenTree/InvenTree/config.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/backend/InvenTree/InvenTree/config.py b/src/backend/InvenTree/InvenTree/config.py index 6f5733d74a..07ba769879 100644 --- a/src/backend/InvenTree/InvenTree/config.py +++ b/src/backend/InvenTree/InvenTree/config.py @@ -223,6 +223,11 @@ def do_typecast(value, type, var_name=None): elif type is dict: value = to_dict(value) + # Special handling for boolean typecasting + elif type is bool: + val = is_true(value) + return val + elif type is not None: # Try to typecast the value try: