Commit 14c0f478 authored by Wietse Kuipers's avatar Wietse Kuipers
Browse files

Unbreak navigation

parent 83b803ae
......@@ -7,6 +7,7 @@ import Icon from 'react-native-vector-icons/MaterialIcons';
import { colors } from '../style';
import styles from './style/sidebar';
import * as navigationActions from '../actions/navigation';
import * as loginActions from '../actions/login';
import { loadProfile } from '../actions/profile';
......@@ -91,6 +92,8 @@ Sidebar.propTypes = {
token: PropTypes.string.isRequired,
logout: PropTypes.func.isRequired,
loadProfile: PropTypes.func.isRequired,
// eslint-disable-next-line react/no-unused-prop-types
navigate: PropTypes.func.isRequired,
};
const mapStateToProps = state => ({
......@@ -101,6 +104,7 @@ const mapStateToProps = state => ({
});
const mapDispatchToProps = dispatch => ({
navigate: (scene, newSection = false) => dispatch(navigationActions.navigate(scene, newSection)),
logout: () => dispatch(loginActions.logout()),
loadProfile: token => dispatch(loadProfile(token)),
});
......
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