getting rid of componentWillMount per React 16 specs

This commit is contained in:
or-else
2018-08-19 19:44:14 +03:00
parent 7ac3041493
commit 94c8bab4ec
2 changed files with 3 additions and 5 deletions
+2 -4
View File
@@ -2043,9 +2043,7 @@ class ContactsView extends React.Component {
this.tnMeContactUpdate = this.tnMeContactUpdate.bind(this);
this.tnMeSubsUpdated = this.tnMeSubsUpdated.bind(this);
this.resetContactList = this.resetContactList.bind(this);
}
componentWillMount() {
var me = Tinode.getMeTopic();
me.onContactUpdate = this.tnMeContactUpdate;
me.onSubsUpdated = this.tnMeSubsUpdated;
@@ -2422,7 +2420,7 @@ class NewTopicView extends React.Component {
this.handleGroupByID = this.handleGroupByID.bind(this);
}
componentWillMount() {
componentDidMount() {
this.props.onInitFind();
}
@@ -3574,7 +3572,7 @@ class MessagesView extends React.Component {
}
}
componentWillMount() {
componentDidMount() {
this.propsChange(this.props);
if (this.messagesScroller) {
this.messagesScroller.addEventListener('scroll', this.fetchMoreMessages);
+1 -1
View File
File diff suppressed because one or more lines are too long