Skip to content

Commit 8fc5efa

Browse files
author
camolezi
committed
Removed front-end network validation
1 parent b27a93d commit 8fc5efa

File tree

1 file changed

+21
-21
lines changed

1 file changed

+21
-21
lines changed

packages/react-app/src/App.jsx

+21-21
Original file line numberDiff line numberDiff line change
@@ -167,26 +167,26 @@ function App(props) {
167167
/* yourMainnetBalance, readContracts, writeContracts, mainnetDAIContract */
168168
]);
169169

170-
let networkDisplay = "";
171-
if (localChainId && selectedChainId && localChainId != selectedChainId) {
172-
networkDisplay = (
173-
<div style={{ zIndex: 2, position: "absolute", right: 0, top: 0, padding: 16 }}>
174-
<Alert
175-
message="⚠️ Wrong Network"
176-
description={
177-
<div>
178-
You have <b>{NETWORK(selectedChainId).name}</b> selected and you need to be on{" "}
179-
<b>{NETWORK(localChainId).name}</b>.
180-
</div>
181-
}
182-
type="error"
183-
closable={false}
184-
/>
185-
</div>
186-
);
187-
} else {
188-
networkDisplay = <div style={{ color: targetNetwork.color }}>{targetNetwork.name}</div>;
189-
}
170+
// let networkDisplay = "";
171+
// if (localChainId && selectedChainId && localChainId != selectedChainId) {
172+
// networkDisplay = (
173+
// <div style={{ zIndex: 2, position: "absolute", right: 0, top: 0, padding: 16 }}>
174+
// <Alert
175+
// message="⚠️ Wrong Network"
176+
// description={
177+
// <div>
178+
// You have <b>{NETWORK(selectedChainId).name}</b> selected and you need to be on{" "}
179+
// <b>{NETWORK(localChainId).name}</b>.
180+
// </div>
181+
// }
182+
// type="error"
183+
// closable={false}
184+
// />
185+
// </div>
186+
// );
187+
// } else {
188+
// networkDisplay = <div style={{ color: targetNetwork.color }}>{targetNetwork.name}</div>;
189+
// }
190190

191191
const loadWeb3Modal = useCallback(async () => {
192192
const provider = await web3Modal.connect();
@@ -209,7 +209,7 @@ function App(props) {
209209
return (
210210
<div className="App">
211211
<Layout>
212-
<AppHeader networkDisplay={networkDisplay} />
212+
<AppHeader networkDisplay="mainnet" />
213213

214214
<Content>
215215
{/* 👨‍💼 Your account is in the top right with a wallet at connect options */}

0 commit comments

Comments
 (0)