From 4e9317a1ae7a0609ae4b4604c50248861f994071 Mon Sep 17 00:00:00 2001 From: Tom Hacohen Date: Thu, 7 Dec 2017 19:26:15 +0000 Subject: [PATCH] Remove redundant fetchJournals from sidebar. --- src/SideMenu.tsx | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/src/SideMenu.tsx b/src/SideMenu.tsx index cda786c..931bdc9 100644 --- a/src/SideMenu.tsx +++ b/src/SideMenu.tsx @@ -17,7 +17,7 @@ import SideMenuJournals from './SideMenuJournals'; import { routeResolver, getPalette } from './App'; -import { store, logout, JournalsType, fetchJournals, StoreState, CredentialsData } from './store'; +import { store, logout, JournalsType, StoreState, CredentialsData } from './store'; import * as C from './Constants'; @@ -43,22 +43,6 @@ class SideMenu extends React.Component { this.props.onCloseDrawerRequest(); } - fetchJournals() { - if (this.props.etesync !== null) { - store.dispatch(fetchJournals(this.props.etesync)); - } - } - - componentDidMount() { - this.fetchJournals(); - } - - componentWillReceiveProps(nextProps: PropsTypeInner) { - if (this.props.etesync !== nextProps.etesync) { - this.fetchJournals(); - } - } - render() { const username = (this.props.etesync && this.props.etesync.credentials.email) ? this.props.etesync.credentials.email