# HG changeset patch # User Matthew Wild # Date 1642254394 0 # Node ID 9d29467f4d5b7dac64206ad00b88513601bfc29f # Parent a1181413a0ebc260c27e8bc3ca54115b9e3dc3db mod_http_xep227: Fix luacheck warnings diff -r a1181413a0eb -r 9d29467f4d5b mod_http_xep227/mod_http_xep227.lua --- a/mod_http_xep227/mod_http_xep227.lua Sat Jan 15 00:38:32 2022 +0100 +++ b/mod_http_xep227/mod_http_xep227.lua Sat Jan 15 13:46:34 2022 +0000 @@ -72,7 +72,7 @@ store_name = "pep_data"; end -- Return driver - return sm.get_driver(session.host, driver_store_name); + return sm.get_driver(host, store_name); end local function handle_export_227(event) @@ -147,7 +147,7 @@ return false; end -- Looks like 227, but check it has at least one host + user element - return not not input_xml_parsed:find("host/user"); + return not not xml_data:find("host/user"); end local function handle_import_227(event) @@ -158,7 +158,7 @@ local input_xml_parsed = xml.parse(input_xml_raw); -- Some sanity checks - if not input_xml_parsed or not is_looking_like_227(input_xml_parsed) then + if not input_xml_parsed or not is_looking_like_xep227(input_xml_parsed) then module:log("warn", "No data to import"); return 422; end