diff --git a/data/core/common.lua b/data/core/common.lua index aa42879..6b9dff7 100644 --- a/data/core/common.lua +++ b/data/core/common.lua @@ -269,6 +269,9 @@ end local function split_on_slash(s, sep_pattern) local t = {} + if s:match("^[/\\]") then + t[#t + 1] = "" + end for fragment in string.gmatch(s, "([^/\\]+)") do t[#t + 1] = fragment end