fix(medusa-js): Use correct customer payment methods path (#1934)
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
import { StoreCustomersListPaymentMethodsRes } from '@medusajs/medusa'
|
import { StoreCustomersListPaymentMethodsRes } from "@medusajs/medusa"
|
||||||
import { ResponsePromise } from "../typings"
|
import { ResponsePromise } from "../typings"
|
||||||
import BaseResource from "./base"
|
import BaseResource from "./base"
|
||||||
|
|
||||||
@@ -9,8 +9,10 @@ class PaymentMethodsResource extends BaseResource {
|
|||||||
* @param customHeaders
|
* @param customHeaders
|
||||||
* @return {StoreCustomersListPaymentMethodsRes}
|
* @return {StoreCustomersListPaymentMethodsRes}
|
||||||
*/
|
*/
|
||||||
list(id: string, customHeaders: Record<string, any> = {}): ResponsePromise<StoreCustomersListPaymentMethodsRes> {
|
list(
|
||||||
const path = `/store/carts/${id}/payment-methods`
|
customHeaders: Record<string, any> = {}
|
||||||
|
): ResponsePromise<StoreCustomersListPaymentMethodsRes> {
|
||||||
|
const path = `/store/customers/me/payment-methods`
|
||||||
return this.client.request("GET", path, undefined, {}, customHeaders)
|
return this.client.request("GET", path, undefined, {}, customHeaders)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user