summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-adblock/luasrc/controller/adblock.lua
diff options
context:
space:
mode:
authorDirk Brenken <dev@brenken.org>2017-08-04 08:34:34 +0200
committerDirk Brenken <dev@brenken.org>2017-08-04 11:12:03 +0200
commit0f13f7eb8174e12b5882f244019a35725f729743 (patch)
tree23b5fa19b8247a8ef545500a53faf94adee48f5e /applications/luci-app-adblock/luasrc/controller/adblock.lua
parentf450c0403d4aa2d1e5cbcb262315121b130990e9 (diff)
luci-app-adblock: sync with adblock 2.8.5
* add preliminary kresd support * small fixes Signed-off-by: Dirk Brenken <dev@brenken.org>
Diffstat (limited to 'applications/luci-app-adblock/luasrc/controller/adblock.lua')
-rw-r--r--applications/luci-app-adblock/luasrc/controller/adblock.lua10
1 files changed, 3 insertions, 7 deletions
diff --git a/applications/luci-app-adblock/luasrc/controller/adblock.lua b/applications/luci-app-adblock/luasrc/controller/adblock.lua
index 03b9fc20eb..efa99b5b89 100644
--- a/applications/luci-app-adblock/luasrc/controller/adblock.lua
+++ b/applications/luci-app-adblock/luasrc/controller/adblock.lua
@@ -5,7 +5,7 @@ module("luci.controller.adblock", package.seeall)
local fs = require("nixio.fs")
local util = require("luci.util")
-local template = require("luci.template")
+local templ = require("luci.template")
local i18n = require("luci.i18n")
function index()
@@ -19,17 +19,13 @@ function index()
entry({"admin", "services", "adblock", "advanced", "blacklist"}, cbi("adblock/blacklist_tab"), _("Edit Blacklist"), 110).leaf = true
entry({"admin", "services", "adblock", "advanced", "whitelist"}, cbi("adblock/whitelist_tab"), _("Edit Whitelist"), 120).leaf = true
entry({"admin", "services", "adblock", "advanced", "configuration"}, cbi("adblock/configuration_tab"), _("Edit Configuration"), 130).leaf = true
- entry({"admin", "services", "adblock", "advanced", "query"}, call("query"), _("Query domains"), 140).leaf = true
+ entry({"admin", "services", "adblock", "advanced", "query"}, template("adblock/query"), _("Query domains"), 140).leaf = true
entry({"admin", "services", "adblock", "advanced", "result"}, call("queryData"), nil, 150).leaf = true
end
function logread()
local logfile = util.trim(util.exec("logread -e 'adblock'"))
- template.render("adblock/logread", {title = i18n.translate("Adblock Logfile"), content = logfile})
-end
-
-function query()
- template.render("adblock/query", {title = i18n.translate("Adblock Domain Query")})
+ templ.render("adblock/logread", {title = i18n.translate("Adblock Logfile"), content = logfile})
end
function queryData(domain)