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(dropbox) fix signing out when switching rec providers

Saúl Ibarra Corretgéf5649efa4949
diff --git a/react/features/recording/components/Recording/StartRecordingDialogContent.js b/react/features/recording/components/Recording/StartRecordingDialogContent.js
index b2146bf1a9..fc9fe6520e 100644
--- a/react/features/recording/components/Recording/StartRecordingDialogContent.js
+++ b/react/features/recording/components/Recording/StartRecordingDialogContent.js
@@ -189,6 +189,19 @@ class StartRecordingDialogContent extends Component<Props> {
}
}
+ /**
+ * Implements {@code Component#componentDidUpdate}.
+ *
+ * @inheritdoc
+ */
+ componentDidUpdate(prevProps) {
+ // Auto sign-out when the use chooses another recording service.
+ if (prevProps.selectedRecordingService === RECORDING_TYPES.DROPBOX
+ && this.props.selectedRecordingService !== RECORDING_TYPES.DROPBOX && this.props.isTokenValid) {
+ this._onSignOut();
+ }
+ }
+
/**
* Renders the component.
*
@@ -508,7 +521,6 @@ class StartRecordingDialogContent extends Component<Props> {
*/
_onRecordingServiceSwitchChange() {
const {
- isTokenValid,
onChange,
selectedRecordingService
} = this.props;
@@ -519,10 +531,6 @@ class StartRecordingDialogContent extends Component<Props> {
}
onChange(RECORDING_TYPES.JITSI_REC_SERVICE);
-
- if (isTokenValid) {
- this._onSignOut();
- }
}
/**