Changeset

9434:b502766a10d7

mod_version: Make 'origin' variable local for consistency Many event handlers start with local origin, stanza = event.origin, event.stanza;
author Kim Alvefur <zash@zash.se>
date Sat, 06 Oct 2018 16:29:42 +0200
parents 9433:13b8d47119ad
children 9435:33301038d3e4
files plugins/mod_version.lua
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_version.lua	Sat Oct 06 16:27:31 2018 +0200
+++ b/plugins/mod_version.lua	Sat Oct 06 16:29:42 2018 +0200
@@ -40,7 +40,7 @@
 end
 
 module:hook("iq-get/host/jabber:iq:version:query", function(event)
-	local stanza = event.stanza;
-	event.origin.send(st.reply(stanza):add_child(query));
+	local origin, stanza = event.origin, event.stanza;
+	origin.send(st.reply(stanza):add_child(query));
 	return true;
 end);