소스 검색

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);