Commit e93497b5 authored by Jesús Espino's avatar Jesús Espino Committed by Harrison Healey

MM-8970: Fix the logout button on select_team screen (#843)

parent b9bfd096
......@@ -6,7 +6,7 @@ import React from 'react';
import {FormattedMessage} from 'react-intl';
import {Link} from 'react-router-dom';
import * as GlobalActions from 'actions/global_actions.jsx';
import {emitUserLoggedOutEvent} from 'actions/global_actions.jsx';
import {addUserToTeamFromInvite} from 'actions/team_actions.jsx';
import TeamStore from 'stores/team_store.jsx';
import UserStore from 'stores/user_store.jsx';
......@@ -73,6 +73,11 @@ export default class SelectTeam extends React.Component {
);
};
handleLogoutClick = (e) => {
e.preventDefault();
emitUserLoggedOutEvent('/login');
}
clearError = (e) => {
e.preventDefault();
......@@ -237,7 +242,7 @@ export default class SelectTeam extends React.Component {
<div className='signup-header'>
<a
href='#'
onClick={GlobalActions.emitUserLoggedOutEvent}
onClick={this.handleLogoutClick}
>
<span className='fa fa-chevron-left'/>
<FormattedMessage id='web.header.logout'/>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment