From 502adad0007b370c6eb89a5f57dbbe31c1ab9e8f Mon Sep 17 00:00:00 2001 From: Augustus <14297860+augustbleeds@users.noreply.github.com> Date: Tue, 11 Jun 2024 10:14:27 -0400 Subject: [PATCH] fix ledger wallet creation (#461) * fix * format --- .../starknet-gauntlet-multisig/src/wrapper/index.ts | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/packages-ts/starknet-gauntlet-multisig/src/wrapper/index.ts b/packages-ts/starknet-gauntlet-multisig/src/wrapper/index.ts index 479da662..1d96a6e0 100644 --- a/packages-ts/starknet-gauntlet-multisig/src/wrapper/index.ts +++ b/packages-ts/starknet-gauntlet-multisig/src/wrapper/index.ts @@ -75,11 +75,16 @@ export const wrapCommand = ( static create = async (flags, args) => { const c = new MsigCommand(flags, args) + c.contractAddress = args[0] + c.command = await registeredCommand.create(flags, [c.contractAddress]) + const env = await deps.makeEnv(flags) - c.wallet = await deps.makeWallet(env) - c.provider = deps.makeProvider(env.providerUrl, c.wallet) - c.contractAddress = args[0] + const { wallet, provider, account } = c.command + c.wallet = wallet + c.provider = provider + c.account = account + c.account = env.account c.multisigAddress = env.multisig const loadResult = contractLoader() @@ -106,8 +111,6 @@ export const wrapCommand = ( contract: {}, } - c.command = await registeredCommand.create(flags, [c.contractAddress]) - c.initialState = await c.fetchMultisigState(c.multisigAddress, c.input.user.proposalId) return c