Skip to content
Snippets Groups Projects
Commit 8c440545 authored by Alf Eaton's avatar Alf Eaton
Browse files

Add omponentWillReceiveProps to LogoutPage

parent a8235ae7
No related branches found
No related tags found
No related merge requests found
......@@ -12,6 +12,14 @@ class Logout extends React.Component {
}
}
componentWillReceiveProps (nextProps) {
const { isAuthenticated, logout } = nextProps
if (isAuthenticated) {
logout()
}
}
render () {
const { isAuthenticated } = this.props
......
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