Changeset

4760:55501fc4394b

mod_iq: Remove unused import of jid.split, bare_sessions and don't unpack event.origin when it isn't used. Waqas.
author Matthew Wild <mwild1@gmail.com>
date Sat, 28 Apr 2012 03:39:12 +0100
parents 4759:c4a0c420d232
children 4761:178f252c31b0
files plugins/mod_iq.lua
diffstat 1 files changed, 3 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_iq.lua	Sat Apr 28 03:34:58 2012 +0100
+++ b/plugins/mod_iq.lua	Sat Apr 28 03:39:12 2012 +0100
@@ -8,10 +8,8 @@
 
 
 local st = require "util.stanza";
-local jid_split = require "util.jid".split;
 
 local full_sessions = full_sessions;
-local bare_sessions = bare_sessions;
 
 if module:get_host_type() == "local" then
 	module:hook("iq/full", function(data)
@@ -33,7 +31,7 @@
 
 module:hook("iq/bare", function(data)
 	-- IQ to bare JID recieved
-	local origin, stanza = data.origin, data.stanza;
+	local stanza = data.stanza;
 	local type = stanza.attr.type;
 
 	-- TODO fire post processing events
@@ -49,7 +47,7 @@
 
 module:hook("iq/self", function(data)
 	-- IQ to self JID recieved
-	local origin, stanza = data.origin, data.stanza;
+	local stanza = data.stanza;
 	local type = stanza.attr.type;
 
 	if type == "get" or type == "set" then
@@ -64,7 +62,7 @@
 
 module:hook("iq/host", function(data)
 	-- IQ to a local host recieved
-	local origin, stanza = data.origin, data.stanza;
+	local stanza = data.stanza;
 	local type = stanza.attr.type;
 
 	if type == "get" or type == "set" then