Updated expenses action in redux to not call more than once
• Updated: - expenses action in redux to not call more than once
This commit is contained in:
parent
33d8f571cd
commit
f7b061845e
@ -10,6 +10,9 @@ export const EXPENSES_FETCH_FAIL = 'EXPENSES_FETCH_FAIL'
|
||||
*/
|
||||
export const fetchExpenses = () => (dispatch, getState) => {
|
||||
if (!me) return
|
||||
|
||||
const isFetched = getState().getIn(['expenses', 'fetched'], false)
|
||||
if (isFetched) return
|
||||
|
||||
dispatch(fetchExpensesRequest())
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user