@onekeyfe/extension-bridge-hosted 2.2.0 → 2.2.2

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.
@@ -12,7 +12,7 @@ import entries from 'lodash/entries';
12
12
  import utils from './utils';
13
13
  import * as uuid from 'uuid';
14
14
  import { JsBridgeBase, consts } from '@onekeyfe/cross-inpage-provider-core';
15
- const { EXT_PORT_OFFSCREEN_TO_BG, EXT_PORT_CS_TO_BG, EXT_PORT_UI_TO_BG, ONEKEY_ALIGN_PRIMARY_ACCOUNT } = consts;
15
+ const { EXT_PORT_OFFSCREEN_TO_BG, EXT_PORT_CS_TO_BG, EXT_PORT_UI_TO_BG, ONEKEY_REQUEST_TO_ALL_CS } = consts;
16
16
  class JsBridgeExtBackground extends JsBridgeBase {
17
17
  constructor(config) {
18
18
  super(config);
@@ -128,7 +128,7 @@ class JsBridgeExtBackground extends JsBridgeBase {
128
128
  data = yield data({ origin });
129
129
  }
130
130
  // Send a notification to the port of the specified origin
131
- if (!targetOrigin || targetOrigin === origin || targetOrigin === ONEKEY_ALIGN_PRIMARY_ACCOUNT) {
131
+ if (!targetOrigin || targetOrigin === origin || targetOrigin === ONEKEY_REQUEST_TO_ALL_CS) {
132
132
  // TODO check ports disconnected
133
133
  this.requestSync({
134
134
  data,
@@ -51,7 +51,7 @@ const entries_1 = __importDefault(require("lodash/entries"));
51
51
  const utils_1 = __importDefault(require("./utils"));
52
52
  const uuid = __importStar(require("uuid"));
53
53
  const cross_inpage_provider_core_1 = require("@onekeyfe/cross-inpage-provider-core");
54
- const { EXT_PORT_OFFSCREEN_TO_BG, EXT_PORT_CS_TO_BG, EXT_PORT_UI_TO_BG, ONEKEY_ALIGN_PRIMARY_ACCOUNT } = cross_inpage_provider_core_1.consts;
54
+ const { EXT_PORT_OFFSCREEN_TO_BG, EXT_PORT_CS_TO_BG, EXT_PORT_UI_TO_BG, ONEKEY_REQUEST_TO_ALL_CS } = cross_inpage_provider_core_1.consts;
55
55
  class JsBridgeExtBackground extends cross_inpage_provider_core_1.JsBridgeBase {
56
56
  constructor(config) {
57
57
  super(config);
@@ -167,7 +167,7 @@ class JsBridgeExtBackground extends cross_inpage_provider_core_1.JsBridgeBase {
167
167
  data = yield data({ origin });
168
168
  }
169
169
  // Send a notification to the port of the specified origin
170
- if (!targetOrigin || targetOrigin === origin || targetOrigin === ONEKEY_ALIGN_PRIMARY_ACCOUNT) {
170
+ if (!targetOrigin || targetOrigin === origin || targetOrigin === ONEKEY_REQUEST_TO_ALL_CS) {
171
171
  // TODO check ports disconnected
172
172
  this.requestSync({
173
173
  data,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onekeyfe/extension-bridge-hosted",
3
- "version": "2.2.0",
3
+ "version": "2.2.2",
4
4
  "keywords": [
5
5
  "cross-inpage-provider"
6
6
  ],
@@ -28,12 +28,12 @@
28
28
  "start": "tsc --watch"
29
29
  },
30
30
  "dependencies": {
31
- "@onekeyfe/cross-inpage-provider-core": "2.2.0",
32
- "@onekeyfe/cross-inpage-provider-types": "2.2.0",
31
+ "@onekeyfe/cross-inpage-provider-core": "2.2.2",
32
+ "@onekeyfe/cross-inpage-provider-types": "2.2.2",
33
33
  "uuid": "^8.3.2"
34
34
  },
35
35
  "devDependencies": {
36
36
  "@types/uuid": "^8.3.4"
37
37
  },
38
- "gitHead": "13b468b24dc8c075cd088d152c11a4b6c7c20dd2"
38
+ "gitHead": "c8e8c48be31f7ab33e4f38edd2cb5230a085563b"
39
39
  }