mirror of
https://github.com/vector-im/element-web.git
synced 2024-11-16 21:24:59 +08:00
Clear Lifecycle.RtsClient on MatrixChat.mount
- otherwise it ends up sitting around and failing later tests.
This commit is contained in:
parent
9ff52b182f
commit
65f351ff22
@ -265,7 +265,11 @@ function _handleRestoreFailure(e) {
|
||||
|
||||
let rtsClient = null;
|
||||
export function initRtsClient(url) {
|
||||
rtsClient = new RtsClient(url);
|
||||
if (url) {
|
||||
rtsClient = new RtsClient(url);
|
||||
} else {
|
||||
rtsClient = null;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -263,11 +263,8 @@ module.exports = React.createClass({
|
||||
window.addEventListener('resize', this.handleResize);
|
||||
this.handleResize();
|
||||
|
||||
if (this.props.config.teamServerConfig &&
|
||||
this.props.config.teamServerConfig.teamServerURL
|
||||
) {
|
||||
Lifecycle.initRtsClient(this.props.config.teamServerConfig.teamServerURL);
|
||||
}
|
||||
const teamServerConfig = this.props.config.teamServerConfig || {};
|
||||
Lifecycle.initRtsClient(teamServerConfig.teamServerURL);
|
||||
|
||||
// if the user has followed a login or register link, don't reanimate
|
||||
// the old creds, but rather go straight to the relevant page
|
||||
|
Loading…
Reference in New Issue
Block a user