aboutsummaryrefslogtreecommitdiffstats
path: root/core/stanza_router.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2017-03-04 17:49:48 +0100
committerKim Alvefur <zash@zash.se>2017-03-04 17:49:48 +0100
commit014168ff18ff0216c649ca687523ab96768a9b0d (patch)
tree91aa73ddb7089baef93b2e47966f53c5c945ed52 /core/stanza_router.lua
parentc284110cb40cb2347f82e974f76eb6bc6927e946 (diff)
downloadprosody-014168ff18ff0216c649ca687523ab96768a9b0d.tar.gz
prosody-014168ff18ff0216c649ca687523ab96768a9b0d.zip
core: Split some very long lines [luacheck]
Diffstat (limited to 'core/stanza_router.lua')
-rw-r--r--core/stanza_router.lua12
1 files changed, 8 insertions, 4 deletions
diff --git a/core/stanza_router.lua b/core/stanza_router.lua
index 228fed80..2312614c 100644
--- a/core/stanza_router.lua
+++ b/core/stanza_router.lua
@@ -38,7 +38,8 @@ local function handle_unhandled_stanza(host, origin, stanza) --luacheck: ignore
if st_type == "error" or (name == "iq" and st_type == "result") then
if st_type == "error" then
local err_type, err_condition, err_message = stanza:get_error();
- log("debug", "Discarding unhandled error %s (%s, %s) from %s: %s", name, err_type, err_condition or "unknown condition", origin_type, stanza:top_tag());
+ log("debug", "Discarding unhandled error %s (%s, %s) from %s: %s",
+ name, err_type, err_condition or "unknown condition", origin_type, stanza:top_tag());
else
log("debug", "Discarding %s from %s of type: %s", name, origin_type, st_type or '<nil>');
end
@@ -52,7 +53,8 @@ local function handle_unhandled_stanza(host, origin, stanza) --luacheck: ignore
origin.send(st.error_reply(stanza, "cancel", "service-unavailable"));
end
else
- log("warn", "Unhandled %s stream element or stanza: %s; xmlns=%s: %s", origin_type, name, xmlns, tostring(stanza)); -- we didn't handle it
+ log("warn", "Unhandled %s stream element or stanza: %s; xmlns=%s: %s",
+ origin_type, name, xmlns, tostring(stanza)); -- we didn't handle it
origin:close("unsupported-stanza-type");
end
end
@@ -211,12 +213,14 @@ function core_route_stanza(origin, stanza)
else
local xmlns = stanza.attr.xmlns;
stanza.attr.xmlns = nil;
- local routed = host_session.events.fire_event("route/remote", { origin = origin, stanza = stanza, from_host = from_host, to_host = host });
+ local routed = host_session.events.fire_event("route/remote", {
+ origin = origin, stanza = stanza, from_host = from_host, to_host = host });
stanza.attr.xmlns = xmlns; -- reset
if not routed then
log("debug", "... no, just kidding.");
if stanza.attr.type == "error" or (stanza.name == "iq" and stanza.attr.type == "result") then return; end
- core_route_stanza(host_session, st.error_reply(stanza, "cancel", "not-allowed", "Communication with remote domains is not enabled"));
+ core_route_stanza(host_session, st.error_reply(stanza, "cancel", "not-allowed",
+ "Communication with remote domains is not enabled"));
end
end
end