Fix crash when no paxel stop reason is given

This commit is contained in:
LoneWolfHT 2021-04-01 09:52:13 -07:00 committed by GitHub
parent 054e1389c4
commit bc519e605a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -152,7 +152,7 @@ local function paxel_stop(pname, reason)
hud_event.new(pname, { hud_event.new(pname, {
name = "ctf_classes:paxel_stop", name = "ctf_classes:paxel_stop",
color = "success", color = "success",
value = table.concat({"Pillar digging stopped", reason, "- wait " .. DIG_COOLDOWN .. "s"}, " "), value = table.concat({"Pillar digging stopped", reason or "unknown", "- wait " .. DIG_COOLDOWN .. "s"}, " "),
}) })
diggers[pname] = minetest.after(DIG_COOLDOWN, function() diggers[pname] = nil end) diggers[pname] = minetest.after(DIG_COOLDOWN, function() diggers[pname] = nil end)
end end