diff options
author | Steven Barth <steven@midlink.org> | 2008-05-26 09:45:12 +0000 |
---|---|---|
committer | Steven Barth <steven@midlink.org> | 2008-05-26 09:45:12 +0000 |
commit | 5f40074c0e2a6193cdd89893309787b2d31a24e4 (patch) | |
tree | a684683ae6c7834036ac80ffddeca51473c2bda9 /core/src/template.lua | |
parent | 1da3c32a73b384e77b5958ac601a232f462d888d (diff) |
* Updated dispatcher to use fastindex if available
* Updated webuci SGI
* Updated dispatcher
Diffstat (limited to 'core/src/template.lua')
-rw-r--r-- | core/src/template.lua | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/core/src/template.lua b/core/src/template.lua index 7fc2958c80..369aa0a30b 100644 --- a/core/src/template.lua +++ b/core/src/template.lua @@ -50,12 +50,6 @@ compiler_enable_bytecode = false -- Define the namespace for template modules viewns = { - translate = function(...) return require("luci.i18n").translate(...) end, - config = function(...) return require("luci.model.uci").get(...) or "" end, - controller = luci.http.dispatcher(), - uploadctrl = luci.http.dispatcher_upload(), - media = luci.config.main.mediaurlbase, - resource = luci.config.main.resourcebase, write = io.write, include = function(name) Template(name):render(getfenv(2)) end, } @@ -94,7 +88,6 @@ function compile(template) -- Replacements local r_include = "')\ninclude('%s')\nwrite('" local r_i18n = "'..translate('%1','%2')..'" - local r_uci = "'..config('%1','%2','%3')..'" local r_pexec = "'..(%s or '')..'" local r_exec = "')\n%s\nwrite('" @@ -106,8 +99,6 @@ function compile(template) re = r_include:format(sanitize(string.sub(v, 2))) elseif p == ":" then re = sanitize(v):gsub(":(.-) (.+)", r_i18n) - elseif p == "~" then - re = sanitize(v):gsub("~(.-)%.(.-)%.(.+)", r_uci) elseif p == "=" then re = r_pexec:format(v:sub(2)) else |