Software /
code /
prosody
Diff
prosodyctl @ 2442:94c676b585c0
prosodyctl: Move definition of prosody singleton to prior to loading datamanager, and add platform
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Sun, 10 Jan 2010 23:11:28 +0000 |
parent | 2439:511ba389147a |
child | 2455:0b3184f3c9e4 |
line wrap: on
line diff
--- a/prosodyctl Sun Jan 10 22:43:28 2010 +0000 +++ b/prosodyctl Sun Jan 10 23:11:28 2010 +0000 @@ -60,6 +60,8 @@ end end +prosody = { hosts = {}, events = events, platform = "posix" }; + local data_path = config.get("*", "core", "data_path") or CFG_DATADIR or "data"; require "util.datamanager".set_data_path(data_path); @@ -111,8 +113,7 @@ local events = require "util.events".new(); -hosts = {}; -prosody = { hosts = hosts, events = events }; +hosts = prosody.hosts; for hostname, config in pairs(config.getconfig()) do hosts[hostname] = { events = events };