modules/admin-mini, modules/admin-full: fix language selection, broke with lua->lmo transition
This commit is contained in:
parent
aed5544dc9
commit
843641d98e
2 changed files with 2 additions and 8 deletions
|
@ -32,10 +32,7 @@ l:value("auto")
|
|||
local i18ndir = luci.i18n.i18ndir .. "default."
|
||||
for k, v in luci.util.kspairs(luci.config.languages) do
|
||||
local file = i18ndir .. k:gsub("_", "-")
|
||||
if k:sub(1, 1) ~= "." and (
|
||||
fs.access(file .. ".lua") or
|
||||
fs.access(file .. ".lua.gz")
|
||||
) then
|
||||
if k:sub(1, 1) ~= "." and fs.access(file .. ".lmo") then
|
||||
l:value(k, v)
|
||||
end
|
||||
end
|
||||
|
|
|
@ -33,10 +33,7 @@ l:value("auto")
|
|||
local i18ndir = luci.i18n.i18ndir .. "default."
|
||||
for k, v in luci.util.kspairs(luci.config.languages) do
|
||||
local file = i18ndir .. k:gsub("_", "-")
|
||||
if k:sub(1, 1) ~= "." and (
|
||||
fs.access(file .. ".lua") or
|
||||
fs.access(file .. ".lua.gz")
|
||||
) then
|
||||
if k:sub(1, 1) ~= "." and fs.access(file .. ".lmo") then
|
||||
l:value(k, v)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue