Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.
TypeScript debiandeep-videojitsijitsi-meetscalable-video-conferencessfuvideovideo-communicationvideo-conferencingwebrtc
fix(av-moderation): whitelist moderators whose affiliation was set before joining
Savely Krasovsky8cf243ebcc11
diff --git a/resources/prosody-plugins/mod_av_moderation_component.lua b/resources/prosody-plugins/mod_av_moderation_component.luaindex c2b2bcc249..2338eae8c0 100644--- a/resources/prosody-plugins/mod_av_moderation_component.lua+++ b/resources/prosody-plugins/mod_av_moderation_component.lua@@ -373,10 +373,15 @@ function occupant_joined(event)-- NOTE for some reason event.occupant.role is not reflecting the actual occupant role (when changed-- from allowners module) but iterating over room occupants returns the correct rolefor _, room_occupant in room:each_occupant() do- -- if it is a moderator, send the whitelist to every moderator+ -- if it is a moderator, make sure it is whitelisted and send the whitelist to every moderatorif room_occupant.nick == occupant.nick and room_occupant.role == 'moderator' then+ local moderator_jid = internal_room_jid_match_rewrite(room_occupant.nick);for _,mediaType in pairs({'audio', 'video', 'desktop'}) do- if room.av_moderation[mediaType] then+ local whitelist = room.av_moderation[mediaType];+ if whitelist then+ if not get_index_in_table(whitelist, moderator_jid) then+ whitelist:push(moderator_jid);+ endnotify_whitelist_change(nil, true, room, mediaType);endend