Workaround for soft-crash with calls on startup
Fixes https://github.com/vector-im/riot-web/issues/11458
This commit is contained in:
parent
9d5f3ce32d
commit
b239fde32d
1 changed files with 7 additions and 0 deletions
|
@ -90,6 +90,13 @@ module.exports = createReactClass({
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
call = CallHandler.getAnyActiveCall();
|
call = CallHandler.getAnyActiveCall();
|
||||||
|
// Ignore calls if we can't get the room associated with them.
|
||||||
|
// I think the underlying problem is that the js-sdk sends events
|
||||||
|
// for calls before it has made the rooms available in the store,
|
||||||
|
// although this isn't confirmed.
|
||||||
|
if (MatrixClientPeg.get().getRoom(call.roomId) === null) {
|
||||||
|
call = null;
|
||||||
|
}
|
||||||
this.setState({ call: call });
|
this.setState({ call: call });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue