luci-base: dispatcher.lua: fix filesystem dependency checks

A variable clash led to declarative `fs` dependencies being ineffective.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 7cfce56553)
This commit is contained in:
Jo-Philipp Wich 2020-01-30 12:19:27 +01:00
parent 4b7fe42410
commit 68784d4e61

View file

@ -17,10 +17,10 @@ _M.fs = fs
-- Index table
local index = nil
local function check_fs_depends(fs)
local function check_fs_depends(spec)
local fs = require "nixio.fs"
for path, kind in pairs(fs) do
for path, kind in pairs(spec) do
if kind == "directory" then
local empty = true
for entry in (fs.dir(path) or function() end) do