Phyks (Lucas Verney)
fffe9c4cd3
Major code review, cleaning the code and adding a lot of comments. Also implements a separate store to keep entities with a reference count and garbage collection. This closes #15. Known issues at the moment are: * Webplayer is no longer working, it has to be refactored. * AlbumPage is to be implemented.
31 lines
640 B
JavaScript
31 lines
640 B
JavaScript
// NPM imports
|
|
import React, { Component } from "react";
|
|
import { bindActionCreators } from "redux";
|
|
import { connect } from "react-redux";
|
|
|
|
// Actions
|
|
import * as actionCreators from "../actions";
|
|
|
|
|
|
/**
|
|
* Logout page
|
|
*/
|
|
export class LogoutPage extends Component {
|
|
componentWillMount () {
|
|
// Logout when component is mounted
|
|
this.props.actions.logoutAndRedirect();
|
|
}
|
|
|
|
render () {
|
|
return (
|
|
<div></div>
|
|
);
|
|
}
|
|
}
|
|
|
|
const mapDispatchToProps = (dispatch) => ({
|
|
actions: bindActionCreators(actionCreators, dispatch)
|
|
});
|
|
|
|
export default connect(null, mapDispatchToProps)(LogoutPage);
|