Created
February 18, 2010 11:35
-
-
Save zeen/307588 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local host = hosts[module.host]; | |
module:hook("presence/full", function(event) | |
local origin, stanza = event.origin, event.stanza; | |
local node, host, resource = jid_split(stanza.attr.to); | |
if not node then return; end -- not to a room | |
local room = host.muc[node.."@"..host]; | |
if not room then | |
origin.send(st.error_reply(stanza, "auth", "not-allowed")); | |
end | |
end); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment