Diff

core/stanza_router.lua @ 1142:0e02b3301e80

stanza_router: Pass session.to_host to modulemanager, fixes modules for s2sin_unauthed
author Matthew Wild <mwild1@gmail.com>
date Sat, 09 May 2009 19:43:11 +0100
parent 1043:ad87f555b484
child 1144:fbd65e966316
line wrap: on
line diff
--- a/core/stanza_router.lua	Fri May 08 04:41:18 2009 +0500
+++ b/core/stanza_router.lua	Sat May 09 19:43:11 2009 +0100
@@ -145,7 +145,7 @@
 -- that is, they are handled by this server
 function core_handle_stanza(origin, stanza)
 	-- Handlers
-	if modules_handle_stanza(select(2, jid_split(stanza.attr.to)) or origin.host, origin, stanza) then return; end
+	if modules_handle_stanza(select(2, jid_split(stanza.attr.to)) or origin.host or origin.to_host, origin, stanza) then return; end
 	if origin.type == "c2s" or origin.type == "s2sin" then
 		if origin.type == "c2s" then
 			if stanza.name == "presence" and origin.roster then