This commit is contained in:
yumoqing 2023-05-31 09:53:05 +08:00
parent 9b2e9141a0
commit c6de661962

View File

@ -50,7 +50,12 @@ class ArgsConvert(object):
try:
v = eval(var,namespace)
except Exception as e:
v = namespace.get(var,default)
v = namespace.get(var, None)
if v:
return v
if callable(default):
return default(var)
return default
return v
def convertUnicode(self,s,namespace,default):