diff options
author | Kim Alvefur <zash@zash.se> | 2019-12-01 12:19:36 +0100 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2019-12-01 12:19:36 +0100 |
commit | a5d6f3717ad968b68b5cdbf4e9ca14d191a933f7 (patch) | |
tree | 35ab7f864fddda55141dde0cd1e278b58a7f1a4f | |
parent | ae49a4500f5f0d9bb9006da73c784d94881cf9f4 (diff) | |
download | prosody-a5d6f3717ad968b68b5cdbf4e9ca14d191a933f7.tar.gz prosody-a5d6f3717ad968b68b5cdbf4e9ca14d191a933f7.zip |
mod_s2s: Use stanza type check instead of duck typing
-rw-r--r-- | plugins/mod_s2s/mod_s2s.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/mod_s2s/mod_s2s.lua b/plugins/mod_s2s/mod_s2s.lua index 82f6a95d..64ca7709 100644 --- a/plugins/mod_s2s/mod_s2s.lua +++ b/plugins/mod_s2s/mod_s2s.lua @@ -521,7 +521,7 @@ local function session_close(session, reason, remote_reason, bounce_reason) log("debug", "Disconnecting %s[%s], <stream:error> is: %s", session.host or session.ip or "(unknown host)", session.type, stanza); session.sends2s(stanza); - elseif reason.name then -- a stanza + elseif st.is_stanza(reason) then log("debug", "Disconnecting %s->%s[%s], <stream:error> is: %s", session.from_host or "(unknown host)", session.to_host or "(unknown host)", session.type, reason); |