-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Initiate return process #22
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
...ages/infrastructure/src/public/saleor/checkout/infrastructure/order-return-products-infra.ts
Outdated
Show resolved
Hide resolved
...ages/infrastructure/src/public/saleor/checkout/infrastructure/order-return-products-infra.ts
Outdated
Show resolved
Hide resolved
@@ -25,6 +26,35 @@ type NextFetchOptions = { next?: { revalidate?: number; tags?: string[] } }; | |||
export type FetchOptions = Omit<RequestInit, "method" | "body"> & | |||
NextFetchOptions; | |||
|
|||
export const secureSaleorClient = ({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure why you've copied the secureSaleorClient
from storefront, what is wrong with the authorization in current graphql client in packages dir?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was misled by the more specific name - secureSaleorClient, which suggested it might have additional security features or enhancements. You are right - current GraphQL client in the packages already handles authorization correctly.
.filter(([_, isSelected]) => isSelected) | ||
.map(([lineId]) => ({ | ||
orderLineId: lineId, | ||
quantity: 0, // despite 0 correct qty from order is returned |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do you need to set quantity as 0?
I want to merge this change because it implements initiation of return process.
Pull Request Checklist