fix FCM initialization and a crash

This commit is contained in:
or-else
2021-04-09 16:31:33 -07:00
parent 390a380763
commit 8504e4a155
6 changed files with 122 additions and 95 deletions
+1 -1
View File
@@ -133,7 +133,7 @@ class MessagesView extends React.Component {
}
}
const topic = this.props.tinode.getTopic(this.state.topic);
const topic = this.props.tinode ? this.props.tinode.getTopic(this.state.topic) : undefined;
if (this.state.topic != prevState.topic) {
if (prevState.topic && !Tinode.isNewGroupTopicName(prevState.topic)) {
this.leave(prevState.topic);