util/stanza.lua
changeset 11089 5705d151ea11
parent 11088 5e09a3389adb
child 11090 2846b6226a8e
--- a/util/stanza.lua	Sat Sep 26 17:30:47 2020 +0200
+++ b/util/stanza.lua	Sat Sep 26 18:07:33 2020 +0200
@@ -459,8 +459,8 @@
 	if type(error_type) == "table" then -- an util.error or similar object
 		if type(error_type.extra) == "table" then
 			extra = error_type.extra;
-			if type(extra.by) == "string" then error_by = extra.by; end
 		end
+		if type(error_type.context) == "table" and type(error_type.context.by) == "string" then error_by = error_type.context.by; end
 		error_type, condition, error_message = error_type.type, error_type.condition, error_type.text;
 	end
 	if t.attr.from == error_by then