Skip to content

Commit

Permalink
Fix JS contract initalization if user is logged out
Browse files Browse the repository at this point in the history
  • Loading branch information
simonesestito committed Jan 13, 2024
1 parent 658d73d commit 5ae42f3
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 12 deletions.
6 changes: 0 additions & 6 deletions web/js/geth_contract.js
Original file line number Diff line number Diff line change
Expand Up @@ -432,13 +432,7 @@ const abi = [
async function _initializeGethContract() {
const web3 = getWeb3();
const user = await getCurrentUser();

if (user === null) {
return;
}

const contract = new web3.eth.Contract(abi, geth_contract_address);

return [contract, user];
}

Expand Down
6 changes: 0 additions & 6 deletions web/js/geth_domains.js
Original file line number Diff line number Diff line change
Expand Up @@ -1073,13 +1073,7 @@ const geth_domains_abi = [
async function _initializeGethDomainsContract() {
const web3 = getWeb3();
const user = await getCurrentUser();

if (user === null) {
return;
}

const contract = new web3.eth.Contract(geth_domains_abi, geth_domains_address);

return [contract, user];
}

Expand Down

0 comments on commit 5ae42f3

Please sign in to comment.