@bufferapp/profile-loader
Advanced tools
Comparing version 0.95.2 to 0.95.3
{ | ||
"name": "@bufferapp/profile-loader", | ||
"version": "0.95.2", | ||
"version": "0.95.3", | ||
"description": "Profile Loader wrapper, renders children once the profiles have loaded", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -8,3 +8,2 @@ import { actionTypes as asyncDataFetchActionTypes } from '@bufferapp/async-data-fetch'; | ||
hasError: false, | ||
user: [], | ||
}; | ||
@@ -28,7 +27,2 @@ | ||
}; | ||
case `user_${asyncDataFetchActionTypes.FETCH_SUCCESS}`: | ||
return { | ||
...state, | ||
user: action.result, | ||
}; | ||
default: | ||
@@ -35,0 +29,0 @@ return state; |
@@ -24,9 +24,2 @@ import { actionTypes as asyncDataFetchActions } from '@bufferapp/async-data-fetch'; | ||
}); | ||
it('updated user information on user_FETCH_SUCCESS', () => { | ||
const state = reducer(undefined, { | ||
type: `user_${asyncDataFetchActions.FETCH_SUCCESS}`, | ||
result: { foo: 'foo' }, | ||
}); | ||
expect(state).toEqual({ hasError: false, loading: true, user: { foo: 'foo' } }); | ||
}); | ||
@@ -33,0 +26,0 @@ it('loads again on profiles_FETCH_START', () => { |
81517
697