diff options
Diffstat (limited to 'sphinx/util/jsdump.py')
-rw-r--r-- | sphinx/util/jsdump.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sphinx/util/jsdump.py b/sphinx/util/jsdump.py index bfdba170b..2be48a34a 100644 --- a/sphinx/util/jsdump.py +++ b/sphinx/util/jsdump.py @@ -83,7 +83,7 @@ def dumps(obj: Any, key: bool = False) -> str: if obj is None: return 'null' elif obj is True or obj is False: - return obj and 'true' or 'false' + return 'true' if obj else 'false' elif isinstance(obj, (int, float)): return str(obj) elif isinstance(obj, dict): |