From c3f329cc80f44818a8b9564daae4cdebf5c0552b Mon Sep 17 00:00:00 2001 From: Filip Sekulic Date: Tue, 6 Dec 2022 15:43:53 +0100 Subject: [PATCH] Transaction security provider feature flag (#16776) --- .metamaskrc.dist | 1 + development/build/scripts.js | 1 + .../settings/experimental-tab/experimental-tab.component.js | 3 ++- 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.metamaskrc.dist b/.metamaskrc.dist index 2cb654cfb..cfb23e1b1 100644 --- a/.metamaskrc.dist +++ b/.metamaskrc.dist @@ -9,6 +9,7 @@ PUBNUB_PUB_KEY= PUBNUB_SUB_KEY= TOKEN_ALLOWANCE_IMPROVEMENTS= PORTFOLIO_URL= +TRANSACTION_SECURITY_PROVIDER= ; Set this to '1' to enable support for Sign-In with Ethereum [EIP-4361](https://eips.ethereum.org/EIPS/eip-4361) SIWE_V1= diff --git a/development/build/scripts.js b/development/build/scripts.js index a961dca92..eff0fac92 100644 --- a/development/build/scripts.js +++ b/development/build/scripts.js @@ -1044,6 +1044,7 @@ async function getEnvironmentVariables({ buildTarget, buildType, version }) { SIWE_V1: config.SIWE_V1 === '1', SWAPS_USE_DEV_APIS: config.SWAPS_USE_DEV_APIS === '1', TOKEN_ALLOWANCE_IMPROVEMENTS: config.TOKEN_ALLOWANCE_IMPROVEMENTS === '1', + TRANSACTION_SECURITY_PROVIDER: config.TRANSACTION_SECURITY_PROVIDER === '1', }; } diff --git a/ui/pages/settings/experimental-tab/experimental-tab.component.js b/ui/pages/settings/experimental-tab/experimental-tab.component.js index d4c362b4b..3f35f7d7f 100644 --- a/ui/pages/settings/experimental-tab/experimental-tab.component.js +++ b/ui/pages/settings/experimental-tab/experimental-tab.component.js @@ -274,7 +274,8 @@ export default class ExperimentalTab extends PureComponent { render() { return (
- {this.renderTransactionSecurityCheckToggle()} + {process.env.TRANSACTION_SECURITY_PROVIDER && + this.renderTransactionSecurityCheckToggle()} {this.renderImprovedTokenAllowanceToggle()} {this.renderOpenSeaEnabledToggle()} {this.renderCollectibleDetectionToggle()}