We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c4e6c32 commit 35f68afCopy full SHA for 35f68af
examples/shopping-cart/src/actions/index.js
@@ -21,8 +21,8 @@ export const addToCart = productId => (dispatch, getState) => {
21
}
22
23
24
-export const checkout = (products) => (dispatch, getState) => {
25
- const cart = getState().cart
+export const checkout = products => (dispatch, getState) => {
+ const { cart } = getState()
26
27
dispatch({
28
type: types.CHECKOUT_REQUEST
0 commit comments