ggez-banking-sdk 0.1.141 → 0.1.143
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/api/data/result.js
CHANGED
|
@@ -22,9 +22,9 @@ const FillResult = (responseData) => {
|
|
|
22
22
|
}
|
|
23
23
|
return {
|
|
24
24
|
code: SystemResponses.Approved,
|
|
25
|
-
message: "",
|
|
26
|
-
friendly_message: "",
|
|
27
|
-
description: "",
|
|
25
|
+
message: "Operation Completed Successfully",
|
|
26
|
+
friendly_message: "Operation Completed Successfully",
|
|
27
|
+
description: "Operation Completed Successfully",
|
|
28
28
|
};
|
|
29
29
|
};
|
|
30
30
|
const FillResultByError = (error) => {
|
|
@@ -100,6 +100,9 @@ class CookiesHelper {
|
|
|
100
100
|
const IID = this.GetIID();
|
|
101
101
|
const DEK = this.GetDEK();
|
|
102
102
|
const USR = this.GetUSR();
|
|
103
|
+
if (!DEK || !USR) {
|
|
104
|
+
return "";
|
|
105
|
+
}
|
|
103
106
|
const { key, iv } = CipherHelper.GenerateByUserID(USR.user_id.toString());
|
|
104
107
|
const DUID = IID + "." + DEK;
|
|
105
108
|
const deviceSecurityCode = CipherHelper.Encrypt(DUID, key, iv);
|
|
@@ -207,11 +210,23 @@ class CookiesHelper {
|
|
|
207
210
|
callback();
|
|
208
211
|
}
|
|
209
212
|
break;
|
|
213
|
+
case "access_token":
|
|
214
|
+
const accessToken = this.GetAccessToken();
|
|
215
|
+
if (accessToken != changedCookie.value) {
|
|
216
|
+
callback();
|
|
217
|
+
}
|
|
218
|
+
break;
|
|
219
|
+
case "jwt_token":
|
|
220
|
+
const jwtToken = this.GetJWTToken();
|
|
221
|
+
if (jwtToken != changedCookie.value) {
|
|
222
|
+
callback();
|
|
223
|
+
}
|
|
224
|
+
break;
|
|
210
225
|
}
|
|
211
226
|
};
|
|
212
227
|
static onDeleteHandler = (deleted, callback) => {
|
|
213
228
|
const deletedCookie = deleted[0];
|
|
214
|
-
if (["DEK", "USR", "IID"].includes(deletedCookie.name)) {
|
|
229
|
+
if (["DEK", "USR", "IID", "access_token", "jwt_token"].includes(deletedCookie.name)) {
|
|
215
230
|
callback();
|
|
216
231
|
}
|
|
217
232
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ggez-banking-sdk",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.143",
|
|
4
4
|
"description": "A Node.js package to handle GGEZ Banking API endpoints, Simplify the process of managing CRUD operations with this efficient and easy-to-use package.",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"main": "dist/index.js",
|