@@ -117,6 +117,7 @@ module.exports = React.createClass({
117
117
guestsCanJoin : false ,
118
118
canPeek : false ,
119
119
showApps : false ,
120
+ isPeeking : false ,
120
121
121
122
// error object, as from the matrix client/server API
122
123
// If we failed to load information about the room,
@@ -266,6 +267,7 @@ module.exports = React.createClass({
266
267
console . log ( "Attempting to peek into room %s" , roomId ) ;
267
268
this . setState ( {
268
269
peekLoading : true ,
270
+ isPeeking : true , // this will change to false if peeking fails
269
271
} ) ;
270
272
MatrixClientPeg . get ( ) . peekInRoom ( roomId ) . then ( ( room ) => {
271
273
this . setState ( {
@@ -290,6 +292,7 @@ module.exports = React.createClass({
290
292
} else if ( room ) {
291
293
// Stop peeking because we have joined this room previously
292
294
MatrixClientPeg . get ( ) . stopPeeking ( ) ;
295
+ this . setState ( { isPeeking : false } ) ;
293
296
}
294
297
} ,
295
298
@@ -1728,8 +1731,8 @@ module.exports = React.createClass({
1728
1731
< TimelinePanel ref = { this . _gatherTimelinePanelRef }
1729
1732
timelineSet = { this . state . room . getUnfilteredTimelineSet ( ) }
1730
1733
showReadReceipts = { ! UserSettingsStore . getSyncedSetting ( 'hideReadReceipts' , false ) }
1731
- manageReadReceipts = { true }
1732
- manageReadMarkers = { true }
1734
+ manageReadReceipts = { ! this . state . isPeeking }
1735
+ manageReadMarkers = { ! this . state . isPeeking }
1733
1736
hidden = { hideMessagePanel }
1734
1737
highlightedEventId = { highlightedEventId }
1735
1738
eventId = { this . state . initialEventId }
0 commit comments