You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-07-16 22:01:54 +03:00
Fix read markers
init code needs to be a constructor or its run too late
This commit is contained in:
@ -109,7 +109,8 @@ export default class MessagePanel extends React.Component {
|
|||||||
showReactions: PropTypes.bool,
|
showReactions: PropTypes.bool,
|
||||||
};
|
};
|
||||||
|
|
||||||
componentDidMount() {
|
constructor() {
|
||||||
|
super();
|
||||||
// the event after which we put a visible unread marker on the last
|
// the event after which we put a visible unread marker on the last
|
||||||
// render cycle; null if readMarkerVisible was false or the RM was
|
// render cycle; null if readMarkerVisible was false or the RM was
|
||||||
// suppressed (eg because it was at the end of the timeline)
|
// suppressed (eg because it was at the end of the timeline)
|
||||||
@ -165,6 +166,10 @@ export default class MessagePanel extends React.Component {
|
|||||||
this._showHiddenEventsInTimeline =
|
this._showHiddenEventsInTimeline =
|
||||||
SettingsStore.getValue("showHiddenEventsInTimeline");
|
SettingsStore.getValue("showHiddenEventsInTimeline");
|
||||||
|
|
||||||
|
this._isMounted = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
componentDidMount() {
|
||||||
this._isMounted = true;
|
this._isMounted = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user