LaunchPaw/contracts/scripts/checkBalance.js
2024-12-26 22:44:48 +03:00

15 lines
379 B
JavaScript

const hre = require("hardhat");
async function main() {
const [deployer] = await hre.ethers.getSigners();
const balance = await hre.ethers.provider.getBalance(deployer.address);
console.log(`Account balance: ${hre.ethers.utils.formatEther(balance)} ETH`);
}
main()
.then(() => process.exit(0))
.catch((error) => {
console.error(error);
process.exit(1);
});