From 15de42a367af26973c2e3099537b86cf8f5ce054 Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Thu, 23 Apr 2020 13:16:25 +0100 Subject: MUC: Always include 'affiliation'/'role' attributes, defaulting to 'none' if nil --- plugins/muc/muc.lib.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/muc/muc.lib.lua b/plugins/muc/muc.lib.lua index bc370da5..93334b88 100644 --- a/plugins/muc/muc.lib.lua +++ b/plugins/muc/muc.lib.lua @@ -143,7 +143,7 @@ end -- actor is the attribute table local function add_item(x, affiliation, role, jid, nick, actor_nick, actor_jid, reason) - x:tag("item", {affiliation = affiliation; role = role; jid = jid; nick = nick;}) + x:tag("item", {affiliation = affiliation or "none"; role = role; jid = jid; nick = nick;}) if actor_nick or actor_jid then x:tag("actor", {nick = actor_nick; jid = actor_jid;}):up() end -- cgit v1.2.3 From dbb7b7b405064e16ec5fbcbffeb44b97c0ad6cbb Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Thu, 23 Apr 2020 13:29:23 +0100 Subject: MUC tests: Add to expected form field --- spec/scansion/muc_register.scs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/spec/scansion/muc_register.scs b/spec/scansion/muc_register.scs index e1eaf4e0..a077cd76 100644 --- a/spec/scansion/muc_register.scs +++ b/spec/scansion/muc_register.scs @@ -100,7 +100,9 @@ Juliet receives: http://jabber.org/protocol/muc#register - + + + @@ -339,7 +341,9 @@ Romeo receives: http://jabber.org/protocol/muc#register - + + + -- cgit v1.2.3 From 4959f37c783799c08de0a640612306c628ee4e27 Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Thu, 23 Apr 2020 13:43:29 +0100 Subject: Backed out changeset 18f2c7bc5795 (was testing against wrong branch) --- spec/scansion/muc_register.scs | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/spec/scansion/muc_register.scs b/spec/scansion/muc_register.scs index a077cd76..e1eaf4e0 100644 --- a/spec/scansion/muc_register.scs +++ b/spec/scansion/muc_register.scs @@ -100,9 +100,7 @@ Juliet receives: http://jabber.org/protocol/muc#register - - - + @@ -341,9 +339,7 @@ Romeo receives: http://jabber.org/protocol/muc#register - - - + -- cgit v1.2.3 From 4b57f0ced9248faa7059d28f38c95be149e96918 Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Thu, 23 Apr 2020 13:44:47 +0100 Subject: MUC tests: Add missing affiliation attribute --- spec/scansion/muc_register.scs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spec/scansion/muc_register.scs b/spec/scansion/muc_register.scs index e1eaf4e0..a7e57177 100644 --- a/spec/scansion/muc_register.scs +++ b/spec/scansion/muc_register.scs @@ -198,7 +198,7 @@ Juliet receives: Romeo receives: - + -- cgit v1.2.3