@jetthai/cuora 1.1.444-dev.0 → 1.1.444-dev.1
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 +2 -0
- package/package.json +1 -1
- package/src/request/request.js +2 -8
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [1.1.444-dev.1](https://github.com/jetthai/cuora-module/compare/v1.1.444-dev.0...v1.1.444-dev.1) (2026-06-24)
|
|
6
|
+
|
|
5
7
|
### [1.1.444-dev.0](https://github.com/jetthai/cuora-module/compare/v1.1.444-dev-1...v1.1.444-dev.0) (2026-06-24)
|
|
6
8
|
|
|
7
9
|
### [1.1.444-dev-1](https://github.com/jetthai/cuora-module/compare/v1.1.444...v1.1.444-dev-1) (2026-06-24)
|
package/package.json
CHANGED
package/src/request/request.js
CHANGED
|
@@ -252,8 +252,8 @@ export default class Request {
|
|
|
252
252
|
async send(req, customToken) {
|
|
253
253
|
try {
|
|
254
254
|
const cancelToken = customToken || this.source.token
|
|
255
|
-
|
|
256
|
-
|
|
255
|
+
// ERR_A103 No token provided 改由後端回傳:不再於送出前自行 throw,
|
|
256
|
+
// 無 token 的非 public 請求一律送後端,由後端判定並回 A103(前台再屏蔽/登出)。
|
|
257
257
|
const requestConfig = this._createConfig(req, cancelToken)
|
|
258
258
|
const configUrls = ['getConfig', 'get-config']
|
|
259
259
|
if (this.isBlocked && !configUrls.includes(requestConfig.url)) {
|
|
@@ -363,12 +363,6 @@ export default class Request {
|
|
|
363
363
|
return queryString ? `${convertedPath}?${queryString}` : convertedPath
|
|
364
364
|
}
|
|
365
365
|
|
|
366
|
-
_checkToken(req) {
|
|
367
|
-
if (!req.isPublic && !this.getToken()) {
|
|
368
|
-
throw { code: 'ERR_A103', url: req.url }
|
|
369
|
-
}
|
|
370
|
-
}
|
|
371
|
-
|
|
372
366
|
getToken() {
|
|
373
367
|
return storage.get(this.key)
|
|
374
368
|
}
|