@plentymarkets/shop-core 1.9.2 → 1.9.4
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/dist/module.json
CHANGED
|
@@ -10,11 +10,25 @@ export const useHandleError = (error) => {
|
|
|
10
10
|
if (error instanceof ApiError) {
|
|
11
11
|
const translationKey = `storefrontError.${error.key}`;
|
|
12
12
|
const message = error.key && $i18n.te(translationKey) ? $i18n.t(translationKey) : error.message;
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
13
|
+
if (error.key === "security.invalidCsrfToken") {
|
|
14
|
+
send({
|
|
15
|
+
type,
|
|
16
|
+
message,
|
|
17
|
+
persist,
|
|
18
|
+
action: {
|
|
19
|
+
text: $i18n.t("reloadPage"),
|
|
20
|
+
onClick: () => {
|
|
21
|
+
window.location.reload();
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
} else {
|
|
26
|
+
send({
|
|
27
|
+
type,
|
|
28
|
+
message,
|
|
29
|
+
persist
|
|
30
|
+
});
|
|
31
|
+
}
|
|
18
32
|
} else {
|
|
19
33
|
const message = $i18n.t("storefrontError.unknownError");
|
|
20
34
|
send({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@plentymarkets/shop-core",
|
|
3
|
-
"version": "1.9.
|
|
3
|
+
"version": "1.9.4",
|
|
4
4
|
"description": "Core module for PlentyONE Shop",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"test:types": "vue-tsc --noEmit && cd playground && vue-tsc --noEmit"
|
|
43
43
|
},
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@plentymarkets/shop-api": "^0.
|
|
45
|
+
"@plentymarkets/shop-api": "^0.133.0",
|
|
46
46
|
"@vue-storefront/sdk": "^3.4.1",
|
|
47
47
|
"js-sha256": "^0.11.0",
|
|
48
48
|
"resolve": "^1.22.10"
|