diff --git a/preload.lua b/preload.lua index ac63be6..095b29c 100644 --- a/preload.lua +++ b/preload.lua @@ -72,8 +72,8 @@ These are the global Hilbish functions that are always available and not part of return end funcdocs = f:read '*a' - local subdocs = table.map(fs.readdir(moddocPath), function(f) - return lunacolors.underline(lunacolors.blue(string.gsub(f, '.txt', ''))) + local subdocs = table.map(fs.readdir(moddocPath), function(fname) + return lunacolors.underline(lunacolors.blue(string.gsub(fname, '.txt', ''))) end) if subdocName == 'index' then funcdocs = funcdocs .. '\nSubdocs: ' .. table.concat(subdocs, ', ')