@vechain/vebetterdao-contracts
Version:
Open-source repository that houses the smart contracts powering the decentralized VeBetterDAO on the VeChain Thor blockchain.
23 lines (22 loc) • 1.1 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.challengesLibraries = challengesLibraries;
const hardhat_1 = require("hardhat");
async function challengesLibraries({ logOutput = false, } = {}) {
const ChallengeCoreLogic = await hardhat_1.ethers.getContractFactory("ChallengeCoreLogic");
const ChallengeCoreLogicLib = (await ChallengeCoreLogic.deploy());
await ChallengeCoreLogicLib.waitForDeployment();
logOutput && console.log("ChallengeCoreLogic Library deployed");
const ChallengeSettlementLogic = await hardhat_1.ethers.getContractFactory("ChallengeSettlementLogic", {
libraries: {
ChallengeCoreLogic: await ChallengeCoreLogicLib.getAddress(),
},
});
const ChallengeSettlementLogicLib = (await ChallengeSettlementLogic.deploy());
await ChallengeSettlementLogicLib.waitForDeployment();
logOutput && console.log("ChallengeSettlementLogic Library deployed");
return {
ChallengeCoreLogic: ChallengeCoreLogicLib,
ChallengeSettlementLogic: ChallengeSettlementLogicLib,
};
}