* Minor bugfixes
[project/luci.git] / core / src / fs.lua
index 0ca191be94791fc20ff4017414186e8d20dfcb48..4639ac4a863ae1d6e28f4eba603b6d07b071089f 100644 (file)
@@ -29,9 +29,7 @@ module("ffluci.fs", package.seeall)
 require("posix")
 
 -- Glob
-function glob(pattern)
-       return posix.glob(pattern)
-end
+glob = posix.glob
 
 -- Checks whether a file exists
 function isfile(filename)
@@ -79,13 +77,7 @@ basename = posix.basename
 dirname = posix.dirname
 
 -- dir wrapper
-function dir(path)
-       local dir = {}
-       for node in posix.files(path) do
-               table.insert(dir, 1, node)
-       end 
-       return dir
-end
+dir = posix.dir
 
 -- Alias for posix.mkdir
 mkdir = posix.mkdir