diff --git a/docs/advanced/AsyncActions.md b/docs/advanced/AsyncActions.md index b223fb0a62..1ffdd4c108 100644 --- a/docs/advanced/AsyncActions.md +++ b/docs/advanced/AsyncActions.md @@ -225,7 +225,7 @@ function selectedReddit(state = 'reactjs', action) { return action.reddit default: return state - } + } } function posts(state = { @@ -234,24 +234,24 @@ function posts(state = { items: [] }, action) { switch (action.type) { - case INVALIDATE_REDDIT: - return Object.assign({}, state, { - didInvalidate: true - }) - case REQUEST_POSTS: - return Object.assign({}, state, { - isFetching: true, - didInvalidate: false - }) - case RECEIVE_POSTS: - return Object.assign({}, state, { - isFetching: false, - didInvalidate: false, - items: action.posts, - lastUpdated: action.receivedAt - }) - default: - return state + case INVALIDATE_REDDIT: + return Object.assign({}, state, { + didInvalidate: true + }) + case REQUEST_POSTS: + return Object.assign({}, state, { + isFetching: true, + didInvalidate: false + }) + case RECEIVE_POSTS: + return Object.assign({}, state, { + isFetching: false, + didInvalidate: false, + items: action.posts, + lastUpdated: action.receivedAt + }) + default: + return state } }