checkFlag
lib.checkFlag
Docs pulled from | This Revision | 4 days ago
Deprecated
Returns true only if there is an attribute and it is true.
Noogle detected
Implementation
The following is the current implementation of this function.
checkFlag =
    attrSet: name:
    if name == "true" then
      true
    else if name == "false" then
      false
    else if (elem name (attrByPath [ "flags" ] [ ] attrSet)) then
      true
    else
      attrByPath [ name ] false attrSet;