diff options
author | Steven Barth <steven@midlink.org> | 2009-01-02 21:33:10 +0000 |
---|---|---|
committer | Steven Barth <steven@midlink.org> | 2009-01-02 21:33:10 +0000 |
commit | 70ded13045e6b882859eeb0acb928eb8cacefd28 (patch) | |
tree | f1aaeaa1da2349686e7d297bd061455df4d21f81 /applications | |
parent | 748bbc8acb42065886d23dc7d95afa218dc42445 (diff) |
Use luci.fs.access instead of luci.fs.isfile where applicable
Diffstat (limited to 'applications')
18 files changed, 18 insertions, 18 deletions
diff --git a/applications/luci-ddns/luasrc/controller/ddns.lua b/applications/luci-ddns/luasrc/controller/ddns.lua index 0adc6abb5a..6adbbb0cae 100644 --- a/applications/luci-ddns/luasrc/controller/ddns.lua +++ b/applications/luci-ddns/luasrc/controller/ddns.lua @@ -17,7 +17,7 @@ module("luci.controller.ddns", package.seeall) function index() require("luci.i18n") luci.i18n.loadc("ddns") - if not luci.fs.isfile("/etc/config/ddns") then + if not luci.fs.access("/etc/config/ddns") then return end diff --git a/applications/luci-hd_idle/luasrc/controller/hd_idle.lua b/applications/luci-hd_idle/luasrc/controller/hd_idle.lua index 45d102cc1e..5dfbe16ea0 100644 --- a/applications/luci-hd_idle/luasrc/controller/hd_idle.lua +++ b/applications/luci-hd_idle/luasrc/controller/hd_idle.lua @@ -18,7 +18,7 @@ module("luci.controller.hd_idle", package.seeall) function index() require("luci.i18n") luci.i18n.loadc("hd_idle") - if not luci.fs.isfile("/etc/config/hd-idle") then + if not luci.fs.access("/etc/config/hd-idle") then return end diff --git a/applications/luci-initmgr/luasrc/controller/init.lua b/applications/luci-initmgr/luasrc/controller/init.lua index aecf6c1863..fbbc7270f9 100644 --- a/applications/luci-initmgr/luasrc/controller/init.lua +++ b/applications/luci-initmgr/luasrc/controller/init.lua @@ -15,7 +15,7 @@ $Id$ module("luci.controller.init", package.seeall) function index() - if not luci.fs.isfile("/etc/rc.common") then + if not luci.fs.access("/etc/rc.common") then return end diff --git a/applications/luci-mmc_over_gpio/luasrc/controller/mmc_over_gpio.lua b/applications/luci-mmc_over_gpio/luasrc/controller/mmc_over_gpio.lua index ce244cb509..7beaa144f0 100644 --- a/applications/luci-mmc_over_gpio/luasrc/controller/mmc_over_gpio.lua +++ b/applications/luci-mmc_over_gpio/luasrc/controller/mmc_over_gpio.lua @@ -18,7 +18,7 @@ module("luci.controller.mmc_over_gpio", package.seeall) function index() require("luci.i18n") luci.i18n.loadc("mmc_over_gpio") - if not luci.fs.isfile("/etc/config/mmc_over_gpio") then + if not luci.fs.access("/etc/config/mmc_over_gpio") then return end diff --git a/applications/luci-ntpc/luasrc/controller/ntpc.lua b/applications/luci-ntpc/luasrc/controller/ntpc.lua index 8fa690f664..9290644680 100644 --- a/applications/luci-ntpc/luasrc/controller/ntpc.lua +++ b/applications/luci-ntpc/luasrc/controller/ntpc.lua @@ -17,7 +17,7 @@ module("luci.controller.ntpc", package.seeall) function index() require("luci.i18n") luci.i18n.loadc("ntpc") - if not luci.fs.isfile("/etc/config/ntpclient") then + if not luci.fs.access("/etc/config/ntpclient") then return end diff --git a/applications/luci-olsr/luasrc/controller/olsr.lua b/applications/luci-olsr/luasrc/controller/olsr.lua index 766107ee9a..652f6b9d2c 100644 --- a/applications/luci-olsr/luasrc/controller/olsr.lua +++ b/applications/luci-olsr/luasrc/controller/olsr.lua @@ -1,7 +1,7 @@ module("luci.controller.olsr", package.seeall) function index() - if not luci.fs.isfile("/etc/config/olsrd") then + if not luci.fs.access("/etc/config/olsrd") then return end diff --git a/applications/luci-p910nd/luasrc/controller/p910nd.lua b/applications/luci-p910nd/luasrc/controller/p910nd.lua index 8cc0e7197a..75b2693d40 100644 --- a/applications/luci-p910nd/luasrc/controller/p910nd.lua +++ b/applications/luci-p910nd/luasrc/controller/p910nd.lua @@ -18,7 +18,7 @@ module("luci.controller.p910nd", package.seeall) function index() require("luci.i18n") luci.i18n.loadc("p910nd") - if not luci.fs.isfile("/etc/config/p910nd") then + if not luci.fs.access("/etc/config/p910nd") then return end diff --git a/applications/luci-polipo/luasrc/controller/polipo.lua b/applications/luci-polipo/luasrc/controller/polipo.lua index c3965ee2e0..949f80a621 100644 --- a/applications/luci-polipo/luasrc/controller/polipo.lua +++ b/applications/luci-polipo/luasrc/controller/polipo.lua @@ -14,7 +14,7 @@ $Id$ module("luci.controller.polipo", package.seeall) function index() - if not luci.fs.isfile("/etc/config/polipo") then + if not luci.fs.access("/etc/config/polipo") then return end diff --git a/applications/luci-qos/luasrc/controller/qos.lua b/applications/luci-qos/luasrc/controller/qos.lua index 5a9ef5e152..970dd3d601 100644 --- a/applications/luci-qos/luasrc/controller/qos.lua +++ b/applications/luci-qos/luasrc/controller/qos.lua @@ -14,7 +14,7 @@ $Id$ module("luci.controller.qos", package.seeall) function index() - if not luci.fs.isfile("/etc/config/qos") then + if not luci.fs.access("/etc/config/qos") then return end diff --git a/applications/luci-samba/luasrc/controller/samba.lua b/applications/luci-samba/luasrc/controller/samba.lua index a698777c2e..75cb65a0b2 100644 --- a/applications/luci-samba/luasrc/controller/samba.lua +++ b/applications/luci-samba/luasrc/controller/samba.lua @@ -15,7 +15,7 @@ $Id$ module("luci.controller.samba", package.seeall) function index() - if not luci.fs.isfile("/etc/config/samba") then + if not luci.fs.access("/etc/config/samba") then return end require("luci.i18n") diff --git a/applications/luci-statistics/luasrc/controller/luci_statistics/luci_statistics.lua b/applications/luci-statistics/luasrc/controller/luci_statistics/luci_statistics.lua index 0aa66362bd..940d2265c7 100644 --- a/applications/luci-statistics/luasrc/controller/luci_statistics/luci_statistics.lua +++ b/applications/luci-statistics/luasrc/controller/luci_statistics/luci_statistics.lua @@ -32,7 +32,7 @@ function index() -- override entry(): check for existance <plugin>.so where <plugin> is derived from the called path function _entry( path, ... ) local file = path[5] or path[4] - if luci.fs.isfile( "/usr/lib/collectd/" .. file .. ".so" ) then + if luci.fs.access( "/usr/lib/collectd/" .. file .. ".so" ) then entry( path, ... ) end end diff --git a/applications/luci-statistics/luasrc/view/admin_statistics/networkplugins.htm b/applications/luci-statistics/luasrc/view/admin_statistics/networkplugins.htm index e29d97c9e3..54ba2b0e26 100644 --- a/applications/luci-statistics/luasrc/view/admin_statistics/networkplugins.htm +++ b/applications/luci-statistics/luasrc/view/admin_statistics/networkplugins.htm @@ -22,7 +22,7 @@ about open tcp connections, interface traffic, iptables rules etc.%></p> <p><%:stat_networkplugins_installed Installed network plugins:%> <ul> <% for plugin, desc in pairs(plugins) do %> - <% if luci.fs.isfile("/usr/lib/collectd/" .. plugin .. ".so") then %> + <% if luci.fs.access("/usr/lib/collectd/" .. plugin .. ".so") then %> <li><a href="<%=controller%>/admin/statistics/collectd/network/<%=plugin%>"><%=desc%></a></li> <% end %> <% end %> diff --git a/applications/luci-statistics/luasrc/view/admin_statistics/outputplugins.htm b/applications/luci-statistics/luasrc/view/admin_statistics/outputplugins.htm index d230109cc0..e79e2f49f5 100644 --- a/applications/luci-statistics/luasrc/view/admin_statistics/outputplugins.htm +++ b/applications/luci-statistics/luasrc/view/admin_statistics/outputplugins.htm @@ -23,7 +23,7 @@ and to transmit the data over the network to other collectd instances.%></p> <p><%:stat_outputplugins_installed Installed output plugins:%> <ul> <% for plugin, desc in pairs(plugins) do %> - <% if luci.fs.isfile("/usr/lib/collectd/" .. plugin .. ".so") then %> + <% if luci.fs.access("/usr/lib/collectd/" .. plugin .. ".so") then %> <li><a href="<%=controller%>/admin/statistics/collectd/output/<%=plugin%>"><%=desc%></a></li> <% end %> <% end %> diff --git a/applications/luci-statistics/luasrc/view/admin_statistics/systemplugins.htm b/applications/luci-statistics/luasrc/view/admin_statistics/systemplugins.htm index bb63228b67..0c1b2b52bb 100644 --- a/applications/luci-statistics/luasrc/view/admin_statistics/systemplugins.htm +++ b/applications/luci-statistics/luasrc/view/admin_statistics/systemplugins.htm @@ -19,7 +19,7 @@ $Id$ <p><%:stat_systemplugins_desc System plugins collecting values about system state and ressource usage on the device.:%> <ul> <% for plugin, desc in pairs(plugins) do %> - <% if luci.fs.isfile("/usr/lib/collectd/" .. plugin .. ".so") then %> + <% if luci.fs.access("/usr/lib/collectd/" .. plugin .. ".so") then %> <li><a href="<%=controller%>/admin/statistics/collectd/system/<%=plugin%>"><%=desc%></a></li> <% end %> <% end %> diff --git a/applications/luci-tinyproxy/luasrc/controller/tinyproxy.lua b/applications/luci-tinyproxy/luasrc/controller/tinyproxy.lua index 2ecfb9383e..fb8d9e2b5d 100644 --- a/applications/luci-tinyproxy/luasrc/controller/tinyproxy.lua +++ b/applications/luci-tinyproxy/luasrc/controller/tinyproxy.lua @@ -15,7 +15,7 @@ $Id$ module("luci.controller.tinyproxy", package.seeall) function index() - if not luci.fs.isfile("/etc/config/tinyproxy") then + if not luci.fs.access("/etc/config/tinyproxy") then return end diff --git a/applications/luci-upnp/luasrc/controller/upnp.lua b/applications/luci-upnp/luasrc/controller/upnp.lua index a7fd66fc11..c88abddc24 100644 --- a/applications/luci-upnp/luasrc/controller/upnp.lua +++ b/applications/luci-upnp/luasrc/controller/upnp.lua @@ -15,7 +15,7 @@ $Id$ module("luci.controller.upnp", package.seeall) function index() - if not luci.fs.isfile("/etc/config/upnpd") then + if not luci.fs.access("/etc/config/upnpd") then return end diff --git a/applications/luci-ushare/luasrc/controller/ushare.lua b/applications/luci-ushare/luasrc/controller/ushare.lua index 2fdea4e830..958f247d98 100644 --- a/applications/luci-ushare/luasrc/controller/ushare.lua +++ b/applications/luci-ushare/luasrc/controller/ushare.lua @@ -18,7 +18,7 @@ module("luci.controller.ushare", package.seeall) function index() require("luci.i18n") luci.i18n.loadc("ushare") - if not luci.fs.isfile("/etc/config/ushare") then + if not luci.fs.access("/etc/config/ushare") then return end diff --git a/applications/luci-uvc_streamer/luasrc/controller/uvc_streamer.lua b/applications/luci-uvc_streamer/luasrc/controller/uvc_streamer.lua index 1766c2b116..64491dc9dc 100644 --- a/applications/luci-uvc_streamer/luasrc/controller/uvc_streamer.lua +++ b/applications/luci-uvc_streamer/luasrc/controller/uvc_streamer.lua @@ -18,7 +18,7 @@ module("luci.controller.uvc_streamer", package.seeall) function index() require("luci.i18n") luci.i18n.loadc("uvc_streamer") - if not luci.fs.isfile("/etc/config/uvc-streamer") then + if not luci.fs.access("/etc/config/uvc-streamer") then return end |