diff options
-rw-r--r-- | app/features/conference/components/Conference.js | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/app/features/conference/components/Conference.js b/app/features/conference/components/Conference.js index 9720b73..f10a7c2 100644 --- a/app/features/conference/components/Conference.js +++ b/app/features/conference/components/Conference.js @@ -150,6 +150,21 @@ class Conference extends Component<Props, State> { } /** + * Handle joining another another meeing while in one. + * + * @param {Object} prevProps - The previous props. + * @returns {void} + */ + componentDidUpdate(prevProps) { + if (prevProps.location.key !== this.props.location.key) { + + // Simulate a re-mount so the new meeting is joined. + this.componentWillUnmount(); + this.componentDidMount(); + } + } + + /** * Implements React's {@link Component#render()}. * * @returns {ReactElement} |