BGM formspec: sanitise title and author
This commit is contained in:
parent
d039b16fe3
commit
cb8b1ea4ff
@ -177,8 +177,8 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
|
|||||||
return
|
return
|
||||||
-- sennò applico la traccia indicata
|
-- sennò applico la traccia indicata
|
||||||
else
|
else
|
||||||
local title = fields.title ~= "" and fields.title or nil
|
local title = fields.title ~= "" and minetest.formspec_escape(fields.title) or nil
|
||||||
local author = fields.author ~= "" and fields.author or nil
|
local author = fields.author ~= "" and minetest.formspec_escape(fields.author) or nil
|
||||||
arena_lib.set_bgm(p_name, mod, arena_name, fields.bgm, title, author, calc_gain(fields.gain), calc_pitch(fields.pitch), true)
|
arena_lib.set_bgm(p_name, mod, arena_name, fields.bgm, title, author, calc_gain(fields.gain), calc_pitch(fields.pitch), true)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user