mirror of
https://gitlab.icynet.eu/evert/fluid_lib.git
synced 2024-12-18 11:15:43 +01:00
Remove translation strings when cleansing node descriptions
This commit is contained in:
parent
6280bab23b
commit
f7250e5bec
@ -32,7 +32,12 @@ function fluid_lib.cleanse_node_description(node)
|
||||
local ndef = minetest.registered_nodes[node]
|
||||
if not ndef then return nil end
|
||||
|
||||
local no_source = ndef.description:gsub("(%s?Source%s?)", "")
|
||||
local desc_no_translation = ndef.description
|
||||
if string.match(desc_no_translation, "^\27") ~= nil then
|
||||
desc_no_translation = desc_no_translation:match("[)]([%w%s]+)\27")
|
||||
end
|
||||
|
||||
local no_source = desc_no_translation:gsub("(%s?Source%s?)", "")
|
||||
|
||||
fluid_lib.fluid_description_cache[node] = no_source
|
||||
return no_source
|
||||
|
Loading…
Reference in New Issue
Block a user