فهرست منبع

fix: fix type error

docs: improve parameter wording
Paul Razvan Berg 1 سال پیش
والد
کامیت
0611674993
2فایلهای تغییر یافته به همراه3 افزوده شده و 3 حذف شده
  1. 1 1
      deploy/deploy.ts
  2. 2 2
      tasks/lock.ts

+ 1 - 1
deploy/deploy.ts

@@ -8,7 +8,7 @@ const UNLOCK_IN_X_DAYS = NOW_IN_SECONDS + DAY_IN_SECONDS * 1; // 1 DAY
 const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) {
   const { deployer } = await hre.getNamedAccounts();
   const { deploy } = hre.deployments;
-  const lockedAmount = hre.ethers.parseEther("0.01");
+  const lockedAmount = hre.ethers.parseEther("0.01").toString();
 
   const lock = await deploy("Lock", {
     from: deployer,

+ 2 - 2
tasks/lock.ts

@@ -47,8 +47,8 @@ task("task:withdraw", "Calls the withdraw function of Lock Contract")
   });
 
 task("task:deployLock", "Deploys Lock Contract")
-  .addParam("unlock", "When to unlock funds in seconds (i.e currentTime + --unlock seconds)")
-  .addParam("value", "How much ether you intend locking (in ether not wei i.e 0.1)")
+  .addParam("unlock", "When to unlock funds in seconds (number of seconds into the futrue)")
+  .addParam("value", "How much ether you intend locking (in ether not wei, e.g., 0.1)")
   .setAction(async function (taskArguments: TaskArguments, { ethers }) {
     const NOW_IN_SECONDS = Math.round(Date.now() / 1000);