@arcblock/bridge 2.8.18 → 2.8.20

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/lib/index.js CHANGED
@@ -11,6 +11,10 @@ function callBridge() {
11
11
  args[_key] = arguments[_key];
12
12
  }
13
13
  Promise.resolve().then(() => _interopRequireWildcard(require('dsbridge'))).then(dsbridge => {
14
+ if (!dsbridge.call) {
15
+ // eslint-disable-next-line no-param-reassign
16
+ dsbridge = dsbridge.default;
17
+ }
14
18
  dsbridge.call(...args);
15
19
  }).catch(err => {
16
20
  console.error('load dsbridge error', err);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arcblock/bridge",
3
- "version": "2.8.18",
3
+ "version": "2.8.20",
4
4
  "description": "a bridge sdk support all js api from DID Wallet.",
5
5
  "keywords": [
6
6
  "bridge",
@@ -41,5 +41,5 @@
41
41
  "eslint-plugin-react-hooks": "^4.6.0",
42
42
  "jest": "^28.1.3"
43
43
  },
44
- "gitHead": "850b2abccbe574066e6cdd012052fb91808a80d2"
44
+ "gitHead": "3e08f2c4f31f4bc26d2bf6d2efe62042f46ecd5b"
45
45
  }
package/src/index.js CHANGED
@@ -1,6 +1,10 @@
1
1
  function callBridge(...args) {
2
2
  import('dsbridge')
3
3
  .then((dsbridge) => {
4
+ if (!dsbridge.call) {
5
+ // eslint-disable-next-line no-param-reassign
6
+ dsbridge = dsbridge.default;
7
+ }
4
8
  dsbridge.call(...args);
5
9
  })
6
10
  .catch((err) => {