Skip to content

Commit

Permalink
deposit check
Browse files Browse the repository at this point in the history
  • Loading branch information
coco-sha committed Aug 5, 2021
1 parent 81bc11d commit 3111bd2
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 4 deletions.
4 changes: 1 addition & 3 deletions abis/YieldSourcePrizePool.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
{
"_format": "hh-sol-artifact-1",
"contractName": "YieldSourcePrizePool",
"sourceName": "contracts/prize-pool/yield-source/YieldSourcePrizePool.sol",
"address": "0x4e8711fC03ae013ab51e8aA96F05B75d5e3C8534",
"abi": [
{
"anonymous": false,
Expand Down
2 changes: 1 addition & 1 deletion scripts/createPool.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ async function main() {
]);

const prizePool = await getContractAt(
YieldSourcePrizePool,
YieldSourcePrizePool.abi,
yieldSourcePrizePoolInitializedEvent[yieldSourcePrizePoolInitializedEvent.length - 1]?.args[
'prizePool'
]
Expand Down
26 changes: 26 additions & 0 deletions scripts/depositCheck.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
const YieldSourcePrizePool = require('../abis/YieldSourcePrizePool.json');

const CONTRACT = '0x4e8711fC03ae013ab51e8aA96F05B75d5e3C8534';

async function main() {
const { ethers } = hre;
const { constants, provider, getContractAt, getContractFactory, getSigners, utils } = ethers;
const { AddressZero } = constants;
const { getBlock, getBlockNumber, getTransactionReceipt, send } = provider;

const prizePool = await getContractAt(
YieldSourcePrizePool.abi,
CONTRACT
);

console.log("Prize Pool: ", prizePool);
}

// We recommend this pattern to be able to use async/await everywhere
// and properly handle errors.
main()
.then(() => process.exit(0))
.catch(error => {
console.error(error);
process.exit(1);
});

0 comments on commit 3111bd2

Please sign in to comment.