Advertisement
Guest User

Untitled

a guest
May 23rd, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. export const fetchUsersAction = dispatch => {
  2.     getData('users').then(snapshot => {
  3.         dispatch({
  4.             type: 'FETCH_USERS',
  5.             payload: snapshot.val()
  6.         });
  7.     }).catch(err => {
  8.         console.error(err)
  9.     });
  10. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement