@@ -92,10 +92,12 @@ in rec {
9292
9393 checkUnitConfig = group: checks: attrs: let
9494 # We're applied at the top-level type (attrsOf unitOption), so the actual
95− # unit options might contain attributes from mkOverride that we need to
95+ # unit options might contain attributes from mkOverride and mkIf that we need to
9696 # convert into single values before checking them.
9797 defs = mapAttrs (const (v:
98− if v._type or "" == "override" then v.content else v
98+ if v._type or "" == "override" then v.content
99+ else if v._type or "" == "if" then v.content
100+ else v
99101 )) attrs;
100102 errors = concatMap (c: c group defs) checks;
101103 in if errors == [] then true