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
feat(av-moderation): Adds desktop media type.
damencho31a30f1118a6
diff --git a/resources/prosody-plugins/mod_av_moderation_component.lua b/resources/prosody-plugins/mod_av_moderation_component.luaindex b10d761c6d..6f2683ebe4 100644--- a/resources/prosody-plugins/mod_av_moderation_component.lua+++ b/resources/prosody-plugins/mod_av_moderation_component.lua@@ -91,7 +91,7 @@ function notify_whitelist_change(jid, moderators, room, mediaType, removed)body_json.mediaType = mediaType;-- sanitize, make sure we don't have an empty array as it will encode it as {} not as []- for _,mediaType in pairs({'audio', 'video'}) do+ for _,mediaType in pairs({'audio', 'video', 'desktop'}) doif body_json.whitelists[mediaType] and #body_json.whitelists[mediaType] == 0 thenbody_json.whitelists[mediaType] = nil;end@@ -215,7 +215,7 @@ function on_message(event)local mediaType = moderation_command.attr.mediaType;if mediaType then- if mediaType ~= 'audio' and mediaType ~= 'video' then+ if mediaType ~= 'audio' and mediaType ~= 'video' and mediaType ~= 'desktop' thenmodule:log('warn', 'Wrong mediaType %s for %s', mediaType, room.jid);return false;end@@ -335,7 +335,7 @@ function occupant_joined(event)and room:get_role(occupant.nick) == 'moderator' thenif not room._data.av_can_unmute then- for _,mediaType in pairs({'audio', 'video'}) do+ for _,mediaType in pairs({'audio', 'video', 'desktop'}) dostart_av_moderation(room, mediaType, occupant);notify_occupants_enable(nil, true, room, occupant.nick, mediaType);@@ -347,7 +347,7 @@ function occupant_joined(event)endif room.av_moderation then- for _,mediaType in pairs({'audio', 'video'}) do+ for _,mediaType in pairs({'audio', 'video', 'desktop'}) doif room.av_moderation[mediaType] thennotify_occupants_enable(occupant.jid, true, room, room.av_moderation_actors[mediaType], mediaType);