Use luci.fs.access instead of luci.fs.isfile where applicable
[project/luci.git] / applications / luci-qos / luasrc / controller / qos.lua
1 --[[
2 LuCI - Lua Configuration Interface
3
4 Copyright 2008 Steven Barth <steven@midlink.org>
5
6 Licensed under the Apache License, Version 2.0 (the "License");
7 you may not use this file except in compliance with the License.
8 You may obtain a copy of the License at
9
10         http://www.apache.org/licenses/LICENSE-2.0
11
12 $Id$
13 ]]--
14 module("luci.controller.qos", package.seeall)
15
16 function index()
17         if not luci.fs.access("/etc/config/qos") then
18                 return
19         end
20         
21         local page = entry({"admin", "network", "qos"}, cbi("qos/qos"), "QoS")
22         page.i18n = "qos"
23         page.dependent = true
24         
25         
26         local page = entry({"mini", "network", "qos"}, cbi("qos/qosmini", {autoapply=true}), "QoS")
27         page.i18n = "qos"
28         page.dependent = true
29 end