Fix replacement tooltip

This commit is contained in:
Jean-Patrick Guerrero 2020-07-12 22:46:28 +02:00
parent 835ab3ba36
commit 1980fefa50

@ -1027,12 +1027,16 @@ local function get_grid_fs(lang_code, fs, rcp, spacing)
local replace local replace
if rcp.replacements then if rcp.replacements then
replace = {}
label = fmt("%s%s\nR", label ~= "" and "\n" or "", label)
for j = 1, #rcp.replacements do for j = 1, #rcp.replacements do
local replacement = rcp.replacements[j] local replacement = rcp.replacements[j]
if replacement[1] == name then if replacement[1] == name then
replace = replace or {}
if j == 1 then
label = fmt("%s%s\nR",
label ~= "" and "\n" or "", label)
end
replace[#replace + 1] = replacement[2] replace[#replace + 1] = replacement[2]
end end
end end