Changeset

10833:ac691f305ea7

mod_csi_simple: Report whatever's not a stirng and not a stanza This is either dead code or actually a type error, but catching that should be the responsibility of the session.send function. This type check is left since everything after it assumes a stanza object. These last few commits aren't meant to change any behavior and it did mark things not stanzas as important, but those would have been mostly raw strings which are now specially handled.
author Kim Alvefur <zash@zash.se>
date Sun, 10 May 2020 23:12:33 +0200
parents 10832:7395f6e68dba
children 10835:e402f808de50
files plugins/mod_csi_simple.lua
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_csi_simple.lua	Sun May 10 23:09:15 2020 +0200
+++ b/plugins/mod_csi_simple.lua	Sun May 10 23:12:33 2020 +0200
@@ -21,7 +21,8 @@
 	elseif type(stanza) == "string" then
 		return true, "raw data";
 	elseif not st.is_stanza(stanza) then
-		return true;
+		-- This should probably never happen
+		return true, type(stanza);
 	end
 	if stanza.attr.xmlns ~= nil then
 		-- stream errors, stream management etc