From f8cc92c190f01c9fc9debddb6f9090ac7b754af8 Mon Sep 17 00:00:00 2001 From: dopik <33575686+dopik@users.noreply.github.com> Date: Mon, 19 Feb 2018 08:41:44 +0100 Subject: [PATCH] /shutdown can't do countdown when using reconnect and/or shutdown message (#7055) Delay was converted from the param string and not the delay value, thus never using the actual given delay value when used in combination with other string values in the param, in this case reconnect and the shutdown messsage. --- builtin/game/chatcommands.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin/game/chatcommands.lua b/builtin/game/chatcommands.lua index e788a2a54..3bd8f2f9c 100644 --- a/builtin/game/chatcommands.lua +++ b/builtin/game/chatcommands.lua @@ -814,7 +814,7 @@ core.register_chatcommand("shutdown", { message = message or "" if delay ~= "" then - delay = tonumber(param) or 0 + delay = tonumber(delay) or 0 else delay = 0 core.log("action", name .. " shuts down server")