Software /
code /
prosody
Diff
core/moduleapi.lua @ 7947:24170d74b00b
core: Split some very long lines [luacheck]
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sat, 04 Mar 2017 17:49:48 +0100 |
parent | 7646:6210dfaec84f |
child | 7950:f91e7ec9654e |
child | 7975:c64ddee9d671 |
line wrap: on
line diff
--- a/core/moduleapi.lua Fri Mar 03 11:51:32 2017 +0100 +++ b/core/moduleapi.lua Sat Mar 04 17:49:48 2017 +0100 @@ -115,7 +115,8 @@ self:log("warn", "Error: Insufficient parameters to module:hook_stanza()"); return; end - return self:hook("stanza/"..(xmlns and (xmlns..":") or "")..name, function (data) return handler(data.origin, data.stanza, data); end, priority); + return self:hook("stanza/"..(xmlns and (xmlns..":") or "")..name, + function (data) return handler(data.origin, data.stanza, data); end, priority); end api.hook_stanza = api.hook_tag; -- COMPAT w/pre-0.9 @@ -187,7 +188,8 @@ local path = paths[i]; if path:sub(1,1) ~= "/" then -- Prepend default components local n_components = select(2, path:gsub("/", "%1")); - path = (n_components<#default_path_components and "/" or "")..t_concat(default_path_components, "/", 1, #default_path_components-n_components).."/"..path; + path = (n_components<#default_path_components and "/" or "") + ..t_concat(default_path_components, "/", 1, #default_path_components-n_components).."/"..path; end local shared = shared_data[path]; if not shared then