diff --git a/framework/vendure/api/checkout.ts b/framework/vendure/api/checkout/index.ts similarity index 90% rename from framework/vendure/api/checkout.ts rename to framework/vendure/api/checkout/index.ts index be10ce609..21083e9b7 100644 --- a/framework/vendure/api/checkout.ts +++ b/framework/vendure/api/checkout/index.ts @@ -1,4 +1,3 @@ -import { BigcommerceConfig, getConfig } from '../../bigcommerce/api' import { NextApiHandler } from 'next' const checkoutApi = async (req: any, res: any, config: any) => { @@ -45,7 +44,7 @@ export function createApiHandler( operations, options, }: { - config?: BigcommerceConfig + config?: any operations?: Partial options?: Options extends {} ? Partial : never } = {}): NextApiHandler { @@ -53,7 +52,7 @@ export function createApiHandler( const opts = { ...defaultOptions, ...options } return function apiHandler(req, res) { - return handler(req, res, getConfig(config), ops, opts) + return handler(req, res, config, ops, opts) } } }