diff options
| author | yo mama <pepper@scannerjammer.com> | 2015-09-22 20:28:06 -0700 |
|---|---|---|
| committer | yo mama <pepper@scannerjammer.com> | 2015-09-22 20:28:06 -0700 |
| commit | 301fc6b40e2465e26981e299838c7d58d0bbeb2c (patch) | |
| tree | 8c7b141f3396b5c0b26aa08161e0b47e04b894a7 /lib/Param/Bool/__init__.py | |
| parent | 87f7b452be8e9e2a59f178236a510747739c4a37 (diff) | |
ok it works!
Diffstat (limited to 'lib/Param/Bool/__init__.py')
| -rw-r--r-- | lib/Param/Bool/__init__.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Param/Bool/__init__.py b/lib/Param/Bool/__init__.py index 8ccca00..7b779cb 100644 --- a/lib/Param/Bool/__init__.py +++ b/lib/Param/Bool/__init__.py @@ -1,5 +1,6 @@ from Param import Param import re +import sys class ParamBool(Param): def __init__(self, value, classname=""): super(ParamBool, self).__init__(classname=classname) @@ -8,7 +9,7 @@ class ParamBool(Param): else: self.value = False def _bool_correct(self, b): - if type(b) == str: + if type(b) == str or type(b) == unicode: if re.match(r'true', b, re.IGNORECASE): return True elif re.match(r'false', b, re.IGNORECASE): |
