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(recording) restore labels when recording locally

Saúl Ibarra Corretgé701e3d2b43c4
diff --git a/react/features/recording/components/AbstractRecordingLabel.ts b/react/features/recording/components/AbstractRecordingLabel.ts
index 0dc4a90fc2..74a28a2d7f 100644
--- a/react/features/recording/components/AbstractRecordingLabel.ts
+++ b/react/features/recording/components/AbstractRecordingLabel.ts
@@ -7,7 +7,8 @@ import { isRecorderTranscriptionsRunning } from '../../transcribing/functions';
import {
getActiveSession,
getSessionStatusToShow,
- isRecordingRunning
+ isRecordingRunning,
+ isRemoteParticipantRecordingLocally
} from '../functions';
export interface IProps extends WithTranslation {
@@ -83,7 +84,8 @@ export function _mapStateToProps(state: IReduxState, ownProps: any) {
const isLivestreamingRunning = Boolean(getActiveSession(state, JitsiRecordingConstants.mode.STREAM));
const _isVisible = isLiveStreamingLabel
? isLivestreamingRunning // this is the livestreaming label
- : isRecordingRunning(state) || _isTranscribing; // this is the recording label
+ : isRecordingRunning(state) || isRemoteParticipantRecordingLocally(state)
+ || _isTranscribing; // this is the recording label
return {
_isVisible,
diff --git a/react/features/recording/functions.ts b/react/features/recording/functions.ts
index b4138fd89c..c08b78b901 100644
--- a/react/features/recording/functions.ts
+++ b/react/features/recording/functions.ts
@@ -140,9 +140,8 @@ export function getSessionStatusToShow(state: IReduxState, mode: string): string
}
}
}
- if ((!Array.isArray(recordingSessions) || recordingSessions.length === 0)
- && mode === JitsiRecordingConstants.mode.FILE
- && (LocalRecordingManager.isRecordingLocally() || isRemoteParticipantRecordingLocally(state))) {
+ if (!status && mode === JitsiRecordingConstants.mode.FILE
+ && (LocalRecordingManager.isRecordingLocally() || isRemoteParticipantRecordingLocally(state))) {
status = JitsiRecordingConstants.status.ON;
}
@@ -349,7 +348,7 @@ export async function sendMeetingHighlight(state: IReduxState) {
* @param {Object} state - Redux state.
* @returns {boolean}
*/
-function isRemoteParticipantRecordingLocally(state: IReduxState) {
+export function isRemoteParticipantRecordingLocally(state: IReduxState) {
const participants = getRemoteParticipants(state);
// eslint-disable-next-line prefer-const