From 301fd957818753c62e3688b5a7f562623c2b295b Mon Sep 17 00:00:00 2001 From: guibescos <59208140+guibescos@users.noreply.github.com> Date: Tue, 14 Feb 2023 05:15:04 -0600 Subject: [PATCH] Restore approve (#591) --- .../xc_admin/packages/xc_admin_common/src/propose.ts | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/governance/xc_admin/packages/xc_admin_common/src/propose.ts b/governance/xc_admin/packages/xc_admin_common/src/propose.ts index e72780e8..7667a249 100644 --- a/governance/xc_admin/packages/xc_admin_common/src/propose.ts +++ b/governance/xc_admin/packages/xc_admin_common/src/propose.ts @@ -16,6 +16,7 @@ import { deriveFeeCollectorKey, } from "@certusone/wormhole-sdk/lib/cjs/solana/wormhole"; import { ExecutePostedVaa } from "./governance_payload/ExecutePostedVaa"; +import { OPS_KEY } from "./multisig"; type SquadInstruction = { instruction: TransactionInstruction; @@ -103,6 +104,12 @@ export async function proposeInstructions( ) ); + txToSend.push( + new Transaction().add( + await squad.buildApproveTransaction(vault, newProposalAddress) + ) + ); + await new AnchorProvider( squad.connection, squad.wallet, @@ -177,7 +184,7 @@ function getPostMessageAccounts( message, emitter, sequence: deriveEmitterSequenceKey(emitter, wormholeAddress), - payer: emitter, + payer: OPS_KEY, feeCollector: deriveFeeCollectorKey(wormholeAddress), clock: SYSVAR_CLOCK_PUBKEY, rent: SYSVAR_RENT_PUBKEY,