@onekeyfe/hd-core 0.1.20 → 0.1.21
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/core/index.d.ts.map +1 -1
- package/dist/index.js +6 -1
- package/package.json +4 -4
- package/src/core/index.ts +8 -1
package/dist/core/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":";AACA,OAAO,YAAY,MAAM,QAAQ,CAAC;AAQlC,OAAO,EACL,WAAW,EAYZ,MAAM,WAAW,CAAC;AAEnB,OAAO,KAAK,EAAE,eAAe,EAAe,MAAM,UAAU,CAAC;AAE7D,OAAO,eAAe,MAAM,2BAA2B,CAAC;AAoBxD,eAAO,MAAM,OAAO,YAAmB,WAAW,iBA6KjD,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":";AACA,OAAO,YAAY,MAAM,QAAQ,CAAC;AAQlC,OAAO,EACL,WAAW,EAYZ,MAAM,WAAW,CAAC;AAEnB,OAAO,KAAK,EAAE,eAAe,EAAe,MAAM,UAAU,CAAC;AAE7D,OAAO,eAAe,MAAM,2BAA2B,CAAC;AAoBxD,eAAO,MAAM,OAAO,YAAmB,WAAW,iBA6KjD,CAAC;AAuKF,eAAO,MAAM,MAAM,0CAkBlB,CAAC;AAiFF,MAAM,CAAC,OAAO,OAAO,IAAK,SAAQ,YAAY;IACtC,aAAa,CAAC,OAAO,EAAE,WAAW;IA+BxC,OAAO;CAGR;AAED,eAAO,MAAM,QAAQ,YAGpB,CAAC;AAEF,eAAO,MAAM,aAAa,uBAGzB,CAAC;AAMF,eAAO,MAAM,IAAI,aAAoB,eAAe,aAAa,GAAG,8BAmBnE,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -13915,7 +13915,12 @@ const ensureConnected = (method, pollingId) => __awaiter(void 0, void 0, void 0,
|
|
|
13915
13915
|
}
|
|
13916
13916
|
catch (error) {
|
|
13917
13917
|
Log.debug('device error: ', error);
|
|
13918
|
-
if (
|
|
13918
|
+
if ([
|
|
13919
|
+
hdShared.HardwareErrorCode.BlePermissionError,
|
|
13920
|
+
hdShared.HardwareErrorCode.BleLocationError,
|
|
13921
|
+
hdShared.HardwareErrorCode.BleDeviceNotBonded,
|
|
13922
|
+
hdShared.HardwareErrorCode.BleCharacteristicNotifyError,
|
|
13923
|
+
].includes(error.errorCode)) {
|
|
13919
13924
|
reject(error);
|
|
13920
13925
|
return;
|
|
13921
13926
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@onekeyfe/hd-core",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.21",
|
|
4
4
|
"description": "> TODO: description",
|
|
5
5
|
"author": "OneKey",
|
|
6
6
|
"homepage": "https://github.com/OneKeyHQ/hardware-js-sdk#readme",
|
|
@@ -25,8 +25,8 @@
|
|
|
25
25
|
"url": "https://github.com/OneKeyHQ/hardware-js-sdk/issues"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@onekeyfe/hd-shared": "^0.1.
|
|
29
|
-
"@onekeyfe/hd-transport": "^0.1.
|
|
28
|
+
"@onekeyfe/hd-shared": "^0.1.21",
|
|
29
|
+
"@onekeyfe/hd-transport": "^0.1.21",
|
|
30
30
|
"axios": "^0.27.2",
|
|
31
31
|
"bignumber.js": "^9.0.2",
|
|
32
32
|
"js-sha256": "^0.9.0",
|
|
@@ -37,5 +37,5 @@
|
|
|
37
37
|
"@types/parse-uri": "^1.0.0",
|
|
38
38
|
"@types/semver": "^7.3.9"
|
|
39
39
|
},
|
|
40
|
-
"gitHead": "
|
|
40
|
+
"gitHead": "807593129b0b2e55dc2beeb7b824494ec8cb07ad"
|
|
41
41
|
}
|
package/src/core/index.ts
CHANGED
|
@@ -356,7 +356,14 @@ const ensureConnected = async (method: BaseMethod, pollingId: number) => {
|
|
|
356
356
|
}
|
|
357
357
|
} catch (error) {
|
|
358
358
|
Log.debug('device error: ', error);
|
|
359
|
-
if (
|
|
359
|
+
if (
|
|
360
|
+
[
|
|
361
|
+
HardwareErrorCode.BlePermissionError,
|
|
362
|
+
HardwareErrorCode.BleLocationError,
|
|
363
|
+
HardwareErrorCode.BleDeviceNotBonded,
|
|
364
|
+
HardwareErrorCode.BleCharacteristicNotifyError,
|
|
365
|
+
].includes(error.errorCode)
|
|
366
|
+
) {
|
|
360
367
|
reject(error);
|
|
361
368
|
return;
|
|
362
369
|
}
|