mod_admin_shell: Allow passing an exit code to server:shutdown()
Mirroring the internal API
--- a/plugins/mod_admin_shell.lua Thu Sep 30 23:22:07 2021 +0200
+++ b/plugins/mod_admin_shell.lua Thu Sep 30 23:22:51 2021 +0200
@@ -330,8 +330,8 @@
minutes, (minutes ~= 1 and "s") or "", os.date("%c", prosody.start_time));
end
-function def_env.server:shutdown(reason)
- prosody.shutdown(reason);
+function def_env.server:shutdown(reason, code)
+ prosody.shutdown(reason, code);
return true, "Shutdown initiated";
end