diff options
author | Jo-Philipp Wich <jow@openwrt.org> | 2009-04-04 22:54:16 +0000 |
---|---|---|
committer | Jo-Philipp Wich <jow@openwrt.org> | 2009-04-04 22:54:16 +0000 |
commit | 9835296ba2623b5c87624da3a8ba5f43595297d0 (patch) | |
tree | 71ab8933e418c25f4b283ff630d643154c168c21 /modules/admin-full/luasrc | |
parent | f3deef9ec570d49795346516d34c1b42fb416fde (diff) |
trunk: prepare LuCI to handle .lua.gz files
Diffstat (limited to 'modules/admin-full/luasrc')
-rw-r--r-- | modules/admin-full/luasrc/model/cbi/admin_index/luci.lua | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/modules/admin-full/luasrc/model/cbi/admin_index/luci.lua b/modules/admin-full/luasrc/model/cbi/admin_index/luci.lua index 20d50cceb5..6ec13b84e0 100644 --- a/modules/admin-full/luasrc/model/cbi/admin_index/luci.lua +++ b/modules/admin-full/luasrc/model/cbi/admin_index/luci.lua @@ -29,7 +29,11 @@ l:value("auto") local i18ndir = luci.i18n.i18ndir .. "default." for k, v in pairs(luci.config.languages) do - if k:sub(1, 1) ~= "." and luci.fs.access(i18ndir .. k:gsub("_", "-") .. ".lua") then + local file = i18ndir .. k:gsub("_", "-") + if k:sub(1, 1) ~= "." and ( + luci.fs.access(file .. ".lua") or + luci.fs.access(file .. ".lua.gz") + ) then l:value(k, v) end end |