Skip to content

Commit

Permalink
done
Browse files Browse the repository at this point in the history
  • Loading branch information
anoushk1234 committed Dec 3, 2022
1 parent 084f07c commit f9dc8f4
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions scripts/airdrop.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,20 @@ const axios = require("axios");
const { create } = require("ipfs-http-client");

async function main() {
const ZoAfterParty = await hre.ethers.getContractFactory("ZoAfterParty");
const zoAfterPartyContract = await ZoAfterParty.deploy();
const zoAfterPartyContract = await hre.ethers.getContractAt(
"ZoAfterParty",
"0xAA6B95fA95a807d31e2E26d194DA5C2F9d516C62"
);
// const zoAfterPartyContract = await ZoAfterParty.deploy();
console.log("ZoAfterParty deployed to:", zoAfterPartyContract.address);

const ipfs = create({
host: "ipfs.infura.io",
port: 5001,
protocol: "https",
});

await zoAfterPartyContract.deployed();
// await zoAfterPartyContract.deployed();

console.log("Contract deployed to:", zoAfterPartyContract.address);

Expand All @@ -39,12 +43,15 @@ async function main() {
address[i].address,
JSON.stringify(metadata)
);

// console.log(txn);
await txn.wait();
// console.log(res);
console.log("success", address[i].address);
} catch (e) {
console.log(e);
console.log("failed", address[i].address);
} finally {
console.log(address[i].walletAddress);
// console.log(address[i].address);
}
}
}
Expand Down

0 comments on commit f9dc8f4

Please sign in to comment.