MM-16815 Remove the failed posts banner on WS reconnect (#2983)

This commit is contained in:
Elias Nahum 2019-07-18 11:36:37 -04:00 committed by GitHub
parent 8a9f1f6ccc
commit 98da0aa607
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 1 deletions

View file

@ -9,7 +9,7 @@ import {init as initWebSocket, close as closeWebSocket} from 'mattermost-redux/a
import {getCurrentChannelId} from 'mattermost-redux/selectors/entities/channels';
import {connection} from 'app/actions/device';
import {markChannelViewedAndRead} from 'app/actions/views/channel';
import {markChannelViewedAndRead, setChannelRetryFailed} from 'app/actions/views/channel';
import {setCurrentUserStatusOffline} from 'app/actions/views/user';
import {getConnection, isLandscape} from 'app/selectors/device';
@ -36,6 +36,7 @@ function mapDispatchToProps(dispatch) {
initWebSocket,
logout,
markChannelViewedAndRead,
setChannelRetryFailed,
setCurrentUserStatusOffline,
startPeriodicStatusUpdates,
stopPeriodicStatusUpdates,

View file

@ -45,6 +45,7 @@ export default class NetworkIndicator extends PureComponent {
initWebSocket: PropTypes.func.isRequired,
markChannelViewedAndRead: PropTypes.func.isRequired,
logout: PropTypes.func.isRequired,
setChannelRetryFailed: PropTypes.func.isRequired,
setCurrentUserStatusOffline: PropTypes.func.isRequired,
startPeriodicStatusUpdates: PropTypes.func.isRequired,
stopPeriodicStatusUpdates: PropTypes.func.isRequired,
@ -165,6 +166,7 @@ export default class NetworkIndicator extends PureComponent {
};
connected = () => {
this.props.actions.setChannelRetryFailed(false);
Animated.sequence([
Animated.timing(
this.backgroundColor, {