def i(node): """Converts an object into an integer, forces 0 """ if node == None: return 0 s = str(node) if s == '': return 0 else: return int(s)