changeset 866:f27d736428f1

core (memory): added 'no' value management in configuration's booleans
author Goffi <goffi@goffi.org>
date Tue, 25 Feb 2014 23:03:13 +0100
parents 3ee2ec7ec010
children 40ad5a344332
files src/memory/memory.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/memory/memory.py	Tue Feb 25 23:01:26 2014 +0100
+++ b/src/memory/memory.py	Tue Feb 25 23:03:13 2014 +0100
@@ -409,7 +409,7 @@
         if attr == 'value':
             value_to_use = value if value is not None else node.getAttribute(attr)  # we use value (user defined) if it exist, else we use node's default value
             if node.getAttribute('type') == 'bool':
-                return value_to_use.lower() not in ('false', '0')
+                return value_to_use.lower() not in ('false', '0', 'no')
             return value_to_use
         return node.getAttribute(attr)