Skip to content

Commit

Permalink
Fix regression with cookies and assortment products
Browse files Browse the repository at this point in the history
  • Loading branch information
pozylon committed Nov 26, 2024
1 parent 3d35192 commit 549b181
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 1 deletion.
1 change: 1 addition & 0 deletions examples/kitchensink/.env.defaults
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,6 @@ UNCHAINED_SEED_PASSWORD=password
UNCHAINED_SECRET=secret
UNCHAINED_CLOUD_ENDPOINT=https://engine.unchained.shop/graphql
UNCHAINED_TOKEN_SECRET=random-token
UNCHAINED_COOKIE_SAMESITE=none
REDIS_DB=0
MONGOMS_VERSION=8.0.1
2 changes: 2 additions & 0 deletions examples/kitchensink/.env.schema
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ UNCHAINED_ASSIGN_CART_FOR_USERS=
UNCHAINED_COOKIE_DOMAIN=
UNCHAINED_COOKIE_PATH=
UNCHAINED_COOKIE_NAME=
UNCHAINED_COOKIE_SAMESITE=
UNCHAINED_COOKIE_INSECURE=
UNCHAINED_TOKEN_SECRET=
DATATRANS_SECRET=
DATATRANS_SIGN_KEY=
Expand Down
2 changes: 2 additions & 0 deletions examples/minimal/.env.defaults
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,7 @@ UNCHAINED_SEED_PASSWORD=password
UNCHAINED_SECRET=secret
UNCHAINED_CLOUD_ENDPOINT=https://engine.unchained.shop/graphql
UNCHAINED_TOKEN_SECRET=random-token-that-is-not-secret-at-all
UNCHAINED_COOKIE_SAMESITE=none
UNCHAINED_COOKIE_INSECURE=
REDIS_DB=0
MONGOMS_VERSION=8.0.1
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,8 @@ export const configureAssortmentProductsModule = ({
if (!options?.skipInvalidation) {
await invalidateCache({ assortmentIds: [assortmentProduct.assortmentId] });
}

return assortmentProduct;
},

delete: async (assortmentProductId, options) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export const updateUserAvatarAfterUploadService: UpdateUserAvatarAfterUploadServ
{ file },
context,
) => {
const { modules, services } = context;
const { modules } = context;
const { userId } = file.meta as { userId: string };

const files = await modules.files.findFiles({
Expand Down

0 comments on commit 549b181

Please sign in to comment.