aboutsummaryrefslogtreecommitdiff
path: root/builtin/game
diff options
context:
space:
mode:
Diffstat (limited to 'builtin/game')
-rw-r--r--builtin/game/chatcommands.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/builtin/game/chatcommands.lua b/builtin/game/chatcommands.lua
index 54cd6c325..5d5955972 100644
--- a/builtin/game/chatcommands.lua
+++ b/builtin/game/chatcommands.lua
@@ -842,7 +842,8 @@ core.register_chatcommand("shutdown", {
core.log("action", name .. " shuts down server")
core.chat_send_all("*** Server shutting down (operator request).")
local reconnect, message = param:match("([^ ]+)(.*)")
- core.request_shutdown(message:trim(), minetest.is_yes(reconnect))
+ message = message or ""
+ core.request_shutdown(message:trim(), core.is_yes(reconnect))
end,
})