# HG changeset patch # User Goffi # Date 1521216009 -3600 # Node ID e96076cdf74c5494d678e351c1763282ecfffbfe # Parent 21d43eab3fb923b460b491c13b6f228c6dcd6069 core (constants): accept "yes" as a True value in bool() diff -r 21d43eab3fb9 -r e96076cdf74c src/core/constants.py --- a/src/core/constants.py Fri Mar 16 16:59:16 2018 +0100 +++ b/src/core/constants.py Fri Mar 16 17:00:09 2018 +0100 @@ -376,7 +376,7 @@ def bool(cls, value): """@return (bool): bool value for associated constant""" assert isinstance(value, basestring) - return value.lower() in (cls.BOOL_TRUE, "1") + return value.lower() in (cls.BOOL_TRUE, "1", "yes") @classmethod def boolConst(cls, value):