From: Jo-Philipp Wich Date: Fri, 16 Apr 2010 19:05:48 +0000 (+0000) Subject: luci-0.9: merge r6081 X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=57dc871f5a90634ea087f0cd3d232046a992cb93;p=project%2Fluci.git luci-0.9: merge r6081 --- diff --git a/libs/web/luasrc/dispatcher.lua b/libs/web/luasrc/dispatcher.lua index 6d44339751..711e4a443c 100644 --- a/libs/web/luasrc/dispatcher.lua +++ b/libs/web/luasrc/dispatcher.lua @@ -146,7 +146,7 @@ function dispatch(request) assert(conf.main, "/etc/config/luci seems to be corrupt, unable to find section 'main'") - local lang = conf.main.lang + local lang = conf.main.lang or "auto" if lang == "auto" then local aclang = http.getenv("HTTP_ACCEPT_LANGUAGE") or "" for lpat in aclang:gmatch("[%w-]+") do @@ -156,7 +156,7 @@ function dispatch(request) break end end - end + end require "luci.i18n".setlanguage(lang) local c = ctx.tree