ifEnable
lib.ifEnable
Docs pulled from | This Revision | about 3 hours ago
of the second argument.
Noogle detected
Implementation
The following is the current implementation of this function.
ifEnable = cond: val:
if cond then val
else if builtins.isList val then []
else if builtins.isAttrs val then {}
# else if builtins.isString val then ""
else if val == true || val == false then false
else null;