Skip to content

Commit 9b4a491

Browse files
authored
Merge branch 'main' into feat/disable-metametrics-basic-functionality
2 parents 5de2448 + c1c3aec commit 9b4a491

File tree

5 files changed

+7
-16
lines changed

5 files changed

+7
-16
lines changed

app/scripts/controllers/bridge-status/bridge-status-controller.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import {
1414
DEFAULT_BRIDGE_STATUS_STATE,
1515
REFRESH_INTERVAL_MS,
1616
} from './constants';
17-
import { BridgeStatusControllerMessenger } from './types';
17+
import type { BridgeStatusControllerMessenger } from './types';
1818
import { fetchBridgeTxStatus, getStatusRequestWithSrcTxHash } from './utils';
1919

2020
const metadata: StateMetadata<BridgeStatusControllerState> = {

app/scripts/controllers/bridge-status/constants.ts

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { BRIDGE_API_BASE_URL } from '../../../../shared/constants/bridge';
12
import { BridgeStatusState } from '../../../../shared/types/bridge-status';
23

34
export const REFRESH_INTERVAL_MS = 10 * 1000;
@@ -11,3 +12,5 @@ export const DEFAULT_BRIDGE_STATUS_STATE: BridgeStatusState = {
1112
export const DEFAULT_BRIDGE_STATUS_CONTROLLER_STATE = {
1213
bridgeStatusState: { ...DEFAULT_BRIDGE_STATUS_STATE },
1314
};
15+
16+
export const BRIDGE_STATUS_BASE_URL = `${BRIDGE_API_BASE_URL}/getTxStatus`;

app/scripts/controllers/bridge-status/utils.ts

+2-6
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
1-
import {
2-
BRIDGE_API_BASE_URL,
3-
BRIDGE_CLIENT_ID,
4-
} from '../../../../shared/constants/bridge';
1+
import { BRIDGE_CLIENT_ID } from '../../../../shared/constants/bridge';
52
import fetchWithCache from '../../../../shared/lib/fetch-with-cache';
63
import {
74
StatusResponse,
@@ -10,11 +7,10 @@ import {
107
} from '../../../../shared/types/bridge-status';
118
import type { Quote } from '../../../../shared/types/bridge';
129
import { validateResponse, validators } from './validators';
10+
import { BRIDGE_STATUS_BASE_URL } from './constants';
1311

1412
const CLIENT_ID_HEADER = { 'X-Client-Id': BRIDGE_CLIENT_ID };
1513

16-
export const BRIDGE_STATUS_BASE_URL = `${BRIDGE_API_BASE_URL}/getTxStatus`;
17-
1814
export const getStatusRequestDto = (
1915
statusRequest: StatusRequestWithSrcTxHash,
2016
): StatusRequestDto => {

app/scripts/controllers/bridge-status/validators.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import {
77
Asset,
88
StatusTypes,
99
} from '../../../../shared/types/bridge-status';
10-
import { BRIDGE_STATUS_BASE_URL } from './utils';
10+
import { BRIDGE_STATUS_BASE_URL } from './constants';
1111

1212
type Validator<ExpectedResponse, DataToValidate> = {
1313
property: keyof ExpectedResponse | string;

development/circular-deps.jsonc

-8
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,6 @@
77
// - For more information contact the Extension Platform team.
88

99
[
10-
[
11-
"app/scripts/controllers/bridge-status/bridge-status-controller.ts",
12-
"app/scripts/controllers/bridge-status/types.ts"
13-
],
14-
[
15-
"app/scripts/controllers/bridge-status/utils.ts",
16-
"app/scripts/controllers/bridge-status/validators.ts"
17-
],
1810
[
1911
"ui/components/app/alert-system/confirm-alert-modal/confirm-alert-modal.tsx",
2012
"ui/components/app/alert-system/confirm-alert-modal/index.tsx",

0 commit comments

Comments
 (0)