@akinon/next 1.43.0-rc.4 → 1.43.0-rc.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/middlewares/default.ts +6 -2
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
package/middlewares/default.ts
CHANGED
|
@@ -85,7 +85,7 @@ const withPzDefault =
|
|
|
85
85
|
req.nextUrl.pathname.includes('/orders/checkout-with-token/')
|
|
86
86
|
) {
|
|
87
87
|
const segment = url.searchParams.get('segment');
|
|
88
|
-
const currency = url.searchParams.get('currency');
|
|
88
|
+
const currency = url.searchParams.get('currency')?.toLowerCase();
|
|
89
89
|
|
|
90
90
|
const headers = {};
|
|
91
91
|
|
|
@@ -114,7 +114,11 @@ const withPzDefault =
|
|
|
114
114
|
}
|
|
115
115
|
|
|
116
116
|
if (currency) {
|
|
117
|
-
response.cookies.set('pz-currency', currency
|
|
117
|
+
response.cookies.set('pz-currency', currency, {
|
|
118
|
+
sameSite: 'none',
|
|
119
|
+
secure: true,
|
|
120
|
+
expires: new Date(Date.now() + 1000 * 60 * 60 * 24 * 7) // 7 days
|
|
121
|
+
});
|
|
118
122
|
}
|
|
119
123
|
|
|
120
124
|
return response;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@akinon/next",
|
|
3
3
|
"description": "Core package for Project Zero Next",
|
|
4
|
-
"version": "1.43.0-rc.
|
|
4
|
+
"version": "1.43.0-rc.5",
|
|
5
5
|
"private": false,
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"bin": {
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"set-cookie-parser": "2.6.0"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
|
-
"@akinon/eslint-plugin-projectzero": "1.43.0-rc.
|
|
33
|
+
"@akinon/eslint-plugin-projectzero": "1.43.0-rc.5",
|
|
34
34
|
"@types/react-redux": "7.1.30",
|
|
35
35
|
"@types/set-cookie-parser": "2.4.7",
|
|
36
36
|
"@typescript-eslint/eslint-plugin": "6.7.4",
|