From 08b5a03be3e6344ed475df7cac56a18bd7330f69 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Sat, 6 Oct 2018 16:38:05 +0200 Subject: mod_version: Reduce scope of variable It is only used in this if block anyways --- plugins/mod_version.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'plugins/mod_version.lua') diff --git a/plugins/mod_version.lua b/plugins/mod_version.lua index 71730ba9..1d24001c 100644 --- a/plugins/mod_version.lua +++ b/plugins/mod_version.lua @@ -10,13 +10,12 @@ local st = require "util.stanza"; module:add_feature("jabber:iq:version"); -local platform; - local query = st.stanza("query", {xmlns = "jabber:iq:version"}) :text_tag("name", "Prosody") :text_tag("version", prosody.version); if not module:get_option_boolean("hide_os_type") then + local platform; if os.getenv("WINDIR") then platform = "Windows"; else -- cgit v1.2.3