clanCore.secrets: facts.value can be null or str
This commit is contained in:
parent
51c1940a1b
commit
5cf9b4428f
|
@ -93,11 +93,12 @@
|
|||
};
|
||||
value = lib.mkOption {
|
||||
defaultText = lib.literalExpression "\${config.clanCore.clanDir}/\${fact.config.path}";
|
||||
type = lib.types.nullOr lib.types.str;
|
||||
default =
|
||||
if builtins.pathExists "${config.clanCore.clanDir}/${fact.config.path}" then
|
||||
builtins.readFile "${config.clanCore.clanDir}/${fact.config.path}"
|
||||
else
|
||||
"";
|
||||
null;
|
||||
};
|
||||
};
|
||||
}));
|
||||
|
|
Loading…
Reference in New Issue
Block a user