diff options
Diffstat (limited to 'acf/path.lua')
-rw-r--r-- | acf/path.lua | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/acf/path.lua b/acf/path.lua index 3a5647d..cd7ea2c 100644 --- a/acf/path.lua +++ b/acf/path.lua @@ -70,6 +70,14 @@ function split(path) end +function is_unique(path) + for _, comp in ipairs(split(path)) do + if comp == wildcard then return false end + end + return true +end + + function to_absolute(path, base) if not is_absolute(path) then path = base..(base ~= '/' and '/' or '')..path |