absolute-pathname: check stringLength > 0
This commit is contained in:
parent
9962ba1036
commit
57098e472a
@ -342,7 +342,9 @@ types // rec {
|
|||||||
absolute-pathname = mkOptionType {
|
absolute-pathname = mkOptionType {
|
||||||
name = "POSIX absolute pathname";
|
name = "POSIX absolute pathname";
|
||||||
check = x: let xs = splitString "/" x; xa = head xs; in
|
check = x: let xs = splitString "/" x; xa = head xs; in
|
||||||
isString x && (xa == "/" || (xa == "" && all filename.check (tail xs)));
|
isString x
|
||||||
|
&& stringLength x > 0
|
||||||
|
&& (xa == "/" || (xa == "" && all filename.check (tail xs)));
|
||||||
merge = mergeOneOption;
|
merge = mergeOneOption;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user