mirror of
https://github.com/minetest-mods/intllib.git
synced 2025-01-08 09:00:26 +01:00
Don't return empty translations
This commit is contained in:
parent
377dc784cd
commit
934ca0492c
5
init.lua
5
init.lua
@ -29,7 +29,10 @@ function intllib.Getter(modname)
|
||||
local msgstr = load_strings(filename)
|
||||
if msgstr then
|
||||
intllib.getters[modname] = function (s)
|
||||
return msgstr[s] or s
|
||||
if msgstr[s] and msgstr[s] ~= "" then
|
||||
return msgstr[s]
|
||||
end
|
||||
return s
|
||||
end
|
||||
else
|
||||
intllib.getters[modname] = noop_getter
|
||||
|
Loading…
Reference in New Issue
Block a user