* luci/libs/uvl: allow empty strings or undefined options as booleans too
This commit is contained in:
parent
0345180f72
commit
77432eb047
1 changed files with 2 additions and 0 deletions
|
@ -29,6 +29,8 @@ function boolean( val )
|
|||
return true
|
||||
elseif val == "0" or val == "no" or val == "off" or val == "false" then
|
||||
return true
|
||||
elseif val == "" or val == nil then
|
||||
return true
|
||||
end
|
||||
|
||||
return false
|
||||
|
|
Loading…
Reference in a new issue