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
Stop peeking if anything went wrong, not just explicit failure
Signed-off-by: Travis Ralston <travpc@gmail.com>
This commit is contained in:
@ -276,6 +276,11 @@ module.exports = React.createClass({
|
||||
});
|
||||
this._onRoomLoaded(room);
|
||||
}, (err) => {
|
||||
// Stop peeking if anything went wrong
|
||||
this.setState({
|
||||
isPeeking: false,
|
||||
});
|
||||
|
||||
// This won't necessarily be a MatrixError, but we duck-type
|
||||
// here and say if it's got an 'errcode' key with the right value,
|
||||
// it means we can't peek.
|
||||
@ -283,7 +288,6 @@ module.exports = React.createClass({
|
||||
// This is fine: the room just isn't peekable (we assume).
|
||||
this.setState({
|
||||
peekLoading: false,
|
||||
isPeeking: false,
|
||||
});
|
||||
} else {
|
||||
throw err;
|
||||
|
Reference in New Issue
Block a user