core (memory/param): don't crash when getting unset int value
This commit is contained in:
parent
68092dd2bb
commit
97f6d1010a
1 changed files with 1 additions and 1 deletions
|
|
@ -415,7 +415,7 @@ class Params(object):
|
|||
if node.getAttribute("type") == "bool":
|
||||
return C.bool(value_to_use)
|
||||
if node.getAttribute("type") == "int":
|
||||
return int(value_to_use)
|
||||
return int(value_to_use) if value_to_use else value_to_use
|
||||
elif node.getAttribute("type") == "list":
|
||||
if (
|
||||
not value_to_use
|
||||
|
|
|
|||
Loading…
Reference in a new issue