整理代码习惯,常量字符串改用单引号,可能有遗漏
This commit is contained in:
@@ -2,9 +2,9 @@ local LANG={}
|
||||
function LANG.init(langList,publicText)--Attention, calling this will destory all initializing methods, create a LANG.set()!
|
||||
local function langFallback(T0,T)
|
||||
for k,v in next,T0 do
|
||||
if type(v)=="table"and not v.refuseCopy then--refuseCopy: just copy pointer, not contents
|
||||
if type(v)=='table'and not v.refuseCopy then--refuseCopy: just copy pointer, not contents
|
||||
if not T[k]then T[k]={}end
|
||||
if type(T[k])=="table"then langFallback(v,T[k])end
|
||||
if type(T[k])=='table'then langFallback(v,T[k])end
|
||||
elseif not T[k]then
|
||||
T[k]=v
|
||||
end
|
||||
@@ -26,7 +26,7 @@ function LANG.init(langList,publicText)--Attention, calling this will destory al
|
||||
end
|
||||
|
||||
--Metatable:__call for table:getTip
|
||||
if type(rawget(L,"getTip"))=="table"then
|
||||
if type(rawget(L,"getTip"))=='table'then
|
||||
setmetatable(L.getTip,tipMeta)
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user