Skip to content

Commit

Permalink
Add log a,d use full empty hash
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremyjams committed Jul 5, 2024
1 parent 4bb4e3a commit 33ec55d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion deploy/1_deploy-ens.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ module.exports = async function () {
const chainId = (await ethers.provider.getNetwork()).chainId;
if (chainId < 1000) {
// skip ENS setup for mainnet and testnet
console.log('Skipping ENS for public networks');
return;
}
const [owner] = await hre.ethers.getSigners();
Expand Down Expand Up @@ -72,7 +73,7 @@ module.exports = async function () {
*/
async function registerDomain(label: string, domain: string = '') {
const name = domain ? `${label}.${domain}` : `${label}`;
const labelHash = label ? labelhash(label) : '0x0';
const labelHash = label ? labelhash(label) : ethers.constants.HashZero;
const nameHash = name ? ethers.utils.namehash(name) : ethers.constants.HashZero;
const existingRegistrarAddress = await ens.owner(nameHash);
let registrar;
Expand Down

0 comments on commit 33ec55d

Please sign in to comment.