rename checkoutCreate to createCart and remove Shopify checkout API

Signed-off-by: Loan Laux <loan@outgrow.io>
This commit is contained in:
Loan Laux
2021-04-27 18:47:39 +04:00
parent f52978e1a3
commit 3496b2a155
7 changed files with 11 additions and 64 deletions

View File

@@ -1,7 +1,7 @@
import type { CartHandlers } from '..'
import {
addCartItemsMutation,
checkoutCreateMutation,
createCartMutation,
} from '@framework/utils/mutations'
import getCartCookie from '@framework/api/utils/get-cart-cookie'
import {
@@ -41,7 +41,7 @@ const addItem: CartHandlers['addItem'] = async ({
if (!item.quantity) item.quantity = 1
if (cartId === config.dummyEmptyCartId) {
const createdCart = await config.fetch(checkoutCreateMutation, {
const createdCart = await config.fetch(createCartMutation, {
variables: {
input: {
shopId: config.shopId,