From 657290679d6a8fba16bd6666561daa7cf74a2947 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Sat, 4 Jul 2020 20:10:18 +0200 Subject: mod_disco: Advertise anonymous users Can these even be seen? --- plugins/mod_disco.lua | 2 ++ 1 file changed, 2 insertions(+) (limited to 'plugins') diff --git a/plugins/mod_disco.lua b/plugins/mod_disco.lua index b05629b5..143e5fa3 100644 --- a/plugins/mod_disco.lua +++ b/plugins/mod_disco.lua @@ -184,6 +184,8 @@ module:hook("iq-get/bare/http://jabber.org/protocol/disco#info:query", function( if not reply.attr.from then reply.attr.from = origin.username.."@"..origin.host; end -- COMPAT To satisfy Psi when querying own account if um_is_admin(stanza.attr.to or origin.full_jid, module.host) then reply:tag('identity', {category='account', type='admin'}):up(); + elseif prosody.hosts[module.host].users.name == "anonymous" then + reply:tag('identity', {category='account', type='anonymous'}):up(); else reply:tag('identity', {category='account', type='registered'}):up(); end -- cgit v1.2.3