comparison plugins/mod_version.lua @ 7982:e30b0cbed472

Merge 0.10->trunk
author Kim Alvefur <zash@zash.se>
date Thu, 16 Mar 2017 23:49:27 +0100
parents 01d6298de991
children c0e058633d9a
comparison
equal deleted inserted replaced
7974:547f000941cf 7982:e30b0cbed472
14 14
15 local query = st.stanza("query", {xmlns = "jabber:iq:version"}) 15 local query = st.stanza("query", {xmlns = "jabber:iq:version"})
16 :tag("name"):text("Prosody"):up() 16 :tag("name"):text("Prosody"):up()
17 :tag("version"):text(prosody.version):up(); 17 :tag("version"):text(prosody.version):up();
18 18
19 if not module:get_option("hide_os_type") then 19 if not module:get_option_boolean("hide_os_type") then
20 if os.getenv("WINDIR") then 20 if os.getenv("WINDIR") then
21 version = "Windows"; 21 version = "Windows";
22 else 22 else
23 local os_version_command = module:get_option("os_version_command"); 23 local os_version_command = module:get_option_string("os_version_command");
24 local ok, pposix = pcall(require, "util.pposix"); 24 local ok, pposix = pcall(require, "util.pposix");
25 if not os_version_command and (ok and pposix and pposix.uname) then 25 if not os_version_command and (ok and pposix and pposix.uname) then
26 version = pposix.uname().sysname; 26 version = pposix.uname().sysname;
27 end 27 end
28 if not version then 28 if not version then