summaryrefslogtreecommitdiff
path: root/photoblaster/param/int_.py
diff options
context:
space:
mode:
Diffstat (limited to 'photoblaster/param/int_.py')
-rw-r--r--photoblaster/param/int_.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/photoblaster/param/int_.py b/photoblaster/param/int_.py
index 8538e6d..6e6d066 100644
--- a/photoblaster/param/int_.py
+++ b/photoblaster/param/int_.py
@@ -13,11 +13,17 @@ class Int(Param):
if value:
self.value = int(value)
else:
- self.value = 0
+ self.value = ""
except Exception as e:
self.err_warn("Not an int: %s" % str(value))
self.err_warn(str(e))
+ def __bool__(self):
+ if not self.value:
+ return False
+ else:
+ return True
+
def __int__(self):
return int(self.value)