From 73fe6591cbe4f9368e03a961d6229bc37626a7bb Mon Sep 17 00:00:00 2001 From: Csongor Kiss Date: Mon, 28 Aug 2023 14:13:43 +0100 Subject: [PATCH] clients/js: fix aptos upgrade and migrate commands For some reason the bound variables in the lambda were underscored, unclear why. In turn, `yargs` referred to the package, resulting in runtime errors. This is the sort of thing that an actual type system would help with. --- clients/js/src/cmds/aptos.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/clients/js/src/cmds/aptos.ts b/clients/js/src/cmds/aptos.ts index 4e775fc79..7f0384d16 100644 --- a/clients/js/src/cmds/aptos.ts +++ b/clients/js/src/cmds/aptos.ts @@ -324,7 +324,7 @@ export const builder = (y: typeof yargs) => .command( "upgrade ", "Perform upgrade after VAA has been submitted", - (_yargs) => + (yargs) => yargs .positional("package-dir", { type: "string", @@ -365,7 +365,7 @@ export const builder = (y: typeof yargs) => .command( "migrate", "Perform migration after contract upgrade", - (_yargs) => + (yargs) => yargs // TODO(csongor): once the sdk has the addresses, just look that up // based on the module