Skip to content

Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.

fix(screenshot-capture): send remote participant id instead of jid (#11132)

Gabriel Borlea4d2000a7a439
diff --git a/react/features/screenshot-capture/ScreenshotCaptureSummary.js b/react/features/screenshot-capture/ScreenshotCaptureSummary.js
index 3eedaa99c5..47a2bc6c82 100644
--- a/react/features/screenshot-capture/ScreenshotCaptureSummary.js
+++ b/react/features/screenshot-capture/ScreenshotCaptureSummary.js
@@ -16,7 +16,6 @@ import {
POLL_INTERVAL,
SET_INTERVAL
} from './constants';
-import { getParticipantJid } from './functions';
import { processScreenshot } from './processScreenshot';
import { timerWorkerScript } from './worker';
@@ -178,10 +177,7 @@ export default class ScreenshotCaptureSummary {
const remoteParticipants = getRemoteParticipants(this._state);
const participants = [];
- remoteParticipants.forEach(p => participants.push(
- getParticipantJid(this._state, p.id)
- ));
-
+ remoteParticipants.forEach(p => participants.push(p.id));
this._storedImageData = imageData;
processScreenshot(this._currentCanvas, {
diff --git a/react/features/screenshot-capture/functions.js b/react/features/screenshot-capture/functions.js
index d79983c571..e4ccfba34a 100644
--- a/react/features/screenshot-capture/functions.js
+++ b/react/features/screenshot-capture/functions.js
@@ -1,6 +1,5 @@
// @flow
-import { getCurrentConference } from '../base/conference';
import { JitsiRecordingConstants } from '../base/lib-jitsi-meet';
import { toState } from '../base/redux';
import { getActiveSession } from '../recording/functions';
@@ -23,29 +22,6 @@ export function createScreenshotCaptureSummary(stateful: Object | Function) {
return new ScreenshotCaptureSummary(toState(stateful));
}
-/**
- * Get a participant's connection JID given its ID.
- *
- * @param {Object} state - The redux store state.
- * @param {string} participantId - ID of the given participant.
- * @returns {string|undefined} - The participant connection JID if found.
- */
-export function getParticipantJid(state: Object, participantId: string) {
- const conference = getCurrentConference(state);
-
- if (!conference) {
- return;
- }
-
- const participant = conference.getParticipantById(participantId);
-
- if (!participant) {
- return;
- }
-
- return participant.getJid();
-}
-
/**
* Checks if the screenshot capture is enabled based on the config.
*