diff options
author | Matthew Wild <mwild1@gmail.com> | 2009-07-18 18:37:06 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2009-07-18 18:37:06 +0100 |
commit | 331d09deb3ba434b9ae73360f6e97f44a110a0cd (patch) | |
tree | c83a5a03a170a3a7d0767d86bcb853d5b1dda2fd /plugins | |
parent | 857dd641dc2be7fd14cb8a34d22890d6ff312012 (diff) | |
download | prosody-331d09deb3ba434b9ae73360f6e97f44a110a0cd.tar.gz prosody-331d09deb3ba434b9ae73360f6e97f44a110a0cd.zip |
mod_console: Add server:shutdown() command
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/mod_console.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/plugins/mod_console.lua b/plugins/mod_console.lua index d505a2e2..28e12a62 100644 --- a/plugins/mod_console.lua +++ b/plugins/mod_console.lua @@ -186,6 +186,11 @@ function def_env.server:uptime() minutes, (minutes ~= 1 and "s") or "", os.date("%c", prosody.start_time)); end +function def_env.server:shutdown(reason) + prosody.shutdown(reason); + return true, "Shutdown initiated"; +end + def_env.module = {}; local function get_hosts_set(hosts, module) |