Software /
code /
prosody
Diff
plugins/muc/mod_muc.lua @ 5016:56a0b13a3d42
mod_muc: Remove unused variable and pull hosts into a local
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Thu, 26 Jul 2012 04:45:22 +0200 |
parent | 5015:f19b38bfa015 |
child | 5058:433cc9a4c7e9 |
line wrap: on
line diff
--- a/plugins/muc/mod_muc.lua Thu Jul 26 04:41:56 2012 +0200 +++ b/plugins/muc/mod_muc.lua Thu Jul 26 04:45:22 2012 +0200 @@ -29,11 +29,11 @@ local uuid_gen = require "util.uuid".generate; local datamanager = require "util.datamanager"; local um_is_admin = require "core.usermanager".is_admin; +local hosts = hosts; rooms = {}; local rooms = rooms; local persistent_rooms = datamanager.load(nil, muc_host, "persistent") or {}; -local component = hosts[module.host]; -- Configurable options local max_history_messages = module:get_option_number("max_history_messages"); @@ -172,7 +172,7 @@ else error("component.send only supports result and error stanzas at the moment"); end end -prosody.hosts[module:get_host()].muc = { rooms = rooms }; +hosts[module:get_host()].muc = { rooms = rooms }; module.save = function() return {rooms = rooms}; @@ -188,5 +188,5 @@ room.save = room_save; rooms[jid] = room; end - prosody.hosts[module:get_host()].muc = { rooms = rooms }; + hosts[module:get_host()].muc = { rooms = rooms }; end