diff --git a/packages/storefront-react/src/context.tsx b/packages/storefront-react/src/context.tsx index 3f67ea9..4c167c0 100755 --- a/packages/storefront-react/src/context.tsx +++ b/packages/storefront-react/src/context.tsx @@ -303,7 +303,7 @@ const ShopProvider: React.FC = ({ async function reloadUserAfterUpdate() { const res = await client.user.getUser({ input: {} }) - if (res.data) { + if (!res.error) { setUser(res.data) } } diff --git a/packages/storefront-shop-adapter-oxid/src/paths.ts b/packages/storefront-shop-adapter-oxid/src/paths.ts index 4853420..567d838 100644 --- a/packages/storefront-shop-adapter-oxid/src/paths.ts +++ b/packages/storefront-shop-adapter-oxid/src/paths.ts @@ -3,13 +3,13 @@ export const USER_GET_CURRENT = '/index.php?cl=MakairaUserController&fnc=getCurrentLoggedInUser' export const USER_LOGOUT = '/index.php?cl=MakairaUserController&fnc=logout' -export const CART_GET = '/index.php?cl=MakairaUserController&fnc=getCartItems' +export const CART_GET = '/index.php?cl=MakairaCartController&fnc=getCartItems' export const CART_ADD = - '/index.php?cl=MakairaUserController&fnc=addProductToCart' + '/index.php?cl=MakairaCartController&fnc=addProductToCart' export const CART_REMOVE = - '/index.php?cl=MakairaUserController&fnc=removeCartItem' + '/index.php?cl=MakairaCartController&fnc=removeCartItem' export const CART_UPDATE = - '/index.php?cl=MakairaUserController&fnc=updateCartItem' + '/index.php?cl=MakairaCartController&fnc=updateCartItem' export const REVIEW_GET = '/index.php?cl=MakairaReviewController&fnc=getReviews' export const REVIEW_CREATE =